I've developing a code very simple but using simultaneous Bars object. I call each one of these Bars object correctly using the BarsInProgress and Close, Closes prices...etc. When I put this Scrip doing backtest with the Strategy Analyzer, I get satisfactory global performance as I expected, BUT when I go into details and watched in Executions I realized that there's no logic continuing between Trades-ID number and its execution time. If you sort all trades by time or by NT-ID number you´ll realize that there are a lot of trades that breaks the logic order.
Following examples attached as jpeg files will show you what I meant.
The explanation to me is that since I work with BarOnClose, every different Bar object has different closing times, so when a signal is triggered "maybe" the system marks that trade when the Bar object is in spite of present time.
- Does this explanation sound logic to you ?
- Should this weird behavior make me not to trust in the code?
If so, what steps should I take in order to avoid these errors?
Thanks
Comment