When I backtest my strategy with Fill type = Default I see that Stop Limit orders are filled "on touch", before entry price is penetrated. This isn't expected, is it? How can I make the fills in backtest work as expected?
- I'm on NT 7
- I use the "advanced managed approach" with liveUntilCancelled = True
- I use a 10 min ES chart where entry orders are submitted on bar close of the 10 min bars on a secondary 1 min TF with entry method EnterLongStopLimit(barsInProgressIndex = 1, liveUntilCancelled = TRUE, ....).
- Stop price and limit price is set 1 tick above the current 10 min bar.
- The option "Enforce Immediate Fills" is not checked under Tools/Options/Simulator.
Below is an example, a chart, the Order tab data and the Execution Tab data. It's obvious that the order was filled intrabar "on touch".
Orders Tab Instrument Action Order Type Qty Limit Stop State Filled Avg Price Remaining Name OCO TIF GTD Account Connection ID Strategy ID Token Time ES ##-## Buy StopLimit 1 1357,75 1357,75 Filled 1 1357,75 0 L_26_0011122010f0001000000_5 Gtc Backtest NT-00218 cec802458e3c4116ac9b8f9332888e72 2001-06-21 21:40
Executions Tab Instrument Action Qty Price Time ID E/X Position Order ID Name Commission Rate Account Connection ES ##-## Buy 1 1357,75 2001-06-21 21:47 NT-00096 Entry 1L NT-00218 L_26_0011122010f0001000000_5 0 1 Backtest
poseidon_sthlm
Comment