So I'm attempting to replace this call...
AddDataSeries(BarsPeriodType.Minute, 1440); // 2nd daily series
with this:
AddDataSeries(Instruments[0].MasterInstrument.Name, new
BarsPeriod() { BarsPeriodType = (BarsPeriodType)5, Value = 1440 }, 30, TradingHours.Name, null);
Unfortunately I'm getting no data back and the second series always has a length of 0 as reported by OnBarsUpdate():
Print(CurrentBars[1]);
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
I understand this is somewhat of a cryptic call but solving this would save me a lot of time as I'm using this indicator in the context of a strategy running on 1-min series.
FWIW - adding this convenience method would help:
AddDataSeries(string instrumentName, BarsPeriodType periodType, int period, int barsToLoad)
Comment