I'm trying to develop and backtest a strategy with intrabar granularity.
I followed example at this link: http://www.ninjatrader.com/support/f...ead.php?t=3572
This sample script works with two DataSeries objects: primary and secondary.
In backtest environment It works fine for entry position. In fact I've found long and short position placed in intrabar time.
The problem is on CloseOrder logic!
My closeorder logic is done by SetTrailStop or SetProfitTarget methods.
When I check my report I notice that all closeorder follow only primary DataSeriers and not secondary Dataseries. It seems that all orderclose are exactly placed at the ends of each minute.
In my script the primary DataSeries is 1 Minute Bars and the secondary Dataseries is 1 Tick.
Before to create my orderclose method without use SetTrailStop and SetProfitTarget
I'd like to know if there is a better solution.
thanks in advance
Comment