Add(PeriodType.Day, 1);
Add("DIA",PeriodType.Minute, 1);
Add(PeriodType.Minute, 15);
The following values are set on the Edit Strategy window:
Type: Minute
Value: 1
Days to load: 12
Maximum bars look back: TwoHundredFiftySix
Min bars required: 21
The strategy never fires because Historical is always false. I added some displays and found that the only values of BarsInProgress are 0, 2, and 3, which means NT's never processing the daily bars and also never building up enough history for that BarsArray.
It seems like other people have experienced the same issue, and there doesn't seem to be a definitive solution to the problem in those threads.
The workaround is to rewrite the code to use daily bars as the primary timeframe, but then I lose other valuable variables that don't seem to have comparable values for multiple timeframes: Bars.BarsSinceSession, BarsSinceEntry, BarsSinceExit. Any ideas?
Comment