I'm looking into integrating all of my instruments into a single strategy run... so that instead of launching 20 charts, I only need to launch one.
So, my plan is to Initialize() and add all of the instruments I'm working with (including multiple timeframes for each strategy). I assume that part will work correctly.
Now... what if I want to include the same instrument *twice* here? Will that work? Will orders be allocated to the correct copy of the instrument? Here's what I mean, exactly:
In initialize():
Add("MSFT", PeriodType.Minute, 5);
Add("MSFT", PeriodType.Minute, 10);
Add("MSFT", PeriodType.Minute, 30);
Add("MSFT", PeriodType.Minute, 5);
Add("MSFT", PeriodType.Minute, 10);
Add("MSFT", PeriodType.Minute, 30);
... will I get two calls into OnBarUpdate, one for each of MSFT at 5 minutes, with their own context set correctly? Or will I break things? I can test the OnBarUpdate part, but what about order handling? Will OnOrderUpdate() be able to figure out which execution belongs to which context?

Comment