This is my first ever post so please bear with me if I screw it up...
I've created a strategy where the entry conditions are given by a combination of 180 minute and 60 minute bars. Basically, I check for entry conditions on the FistTickOfBar. For example, if I were trading live, at 11:00, on the 180 minute bar (timestamped 14:00) I would check the previous bar (from 8:00 to 11:00) and I would check the 10:00 (timestamped 11:00) 60 minute bar (from 10:00 to 11:00)
The problem I have is the following:
If my understanding is correct, when backtesting, bar sequence will be
11:00 180 minute bar
11:00 60 minute bar
12:00 60 minute bar
13:00 60 minute bar
14:00 180 minute bar
...
While on live trading, the sequence would be:
14:00 180 minute bar
11:00 60 minute bar
12:00 60 minute bar
13:00 60 minute bar
17:00 180 minute bar
...
#1 Is my understanding correct on how the bars are read?
If so, my question is:
#2 Does anyone know how to emulate the behavior of live trading during the backtest? I have not been able to perform adequate backtests because of this. Basically, I can "read" the correct 180 minute bar, but I'm reading the wrong 60 minute chart, actually, three hours wrong...
I would appreciate any and all help. Thanks!
Comment