I've been digging around for answers and I've discovered it's best to type up the script myself, rather than having to rely on the strategy wizard. What are my options here?
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Incorrect price appearing on the execution data grid
Collapse
X
-
Incorrect price appearing on the execution data grid
I've been working with Ninjascript for a while now and just when I thought I had nailed my backtesting strategy, I realized that the execution data grid was displaying the incorrect price entry and exit. What do I need to do to get this to display the proper entry and exit?
I've been digging around for answers and I've discovered it's best to type up the script myself, rather than having to rely on the strategy wizard. What are my options here?Tags: None
-
Welcome to the forums escobar63!
Historical order fill simulations are estimated from the OHLC values of the data series the strategy is applied against. If your strategy does not use multiple time frames or Tick Replay, High Order Fill Resolution can be used to simulate order fills with a smaller data series, like a single tick data series. Alternatively, the strategy can be written to submit orders to a single tick data series for order fills that are more consistent with real market movement.
Strategies can also be tested with Market Replay data in the playback connection to have orders filled as if they were submitted in a realtime context.
Discrepancies Between Realtime and Backtest - https://ninjatrader.com/support/help...ime_vs_bac.htm
Historical Fill Processing - https://ninjatrader.com/support/help...ical_fill_.htm
Backtesting with Intrabar Granularity — https://ninjatrader.com/support/help...ipt_strate.htm
For a more comprehensive study on these differences, my colleague Chelsea has a series of videos comparing the different scenarios where order fills are simulated.
Comparing real-time, historical, and replay performance — https://ninjatrader.com/support/foru...mance?t=102504
Please let me know if I can be of further assistance.
-
Hello escobar63,
Adding intrabar granularity would involve submitting orders to a single tick data series so the orders will be filled following intrabar movement. (The OHLC values would be the tick price, and that tick price would be used for the order fill.)
As for Chelsea's videos, they are linked within his forum post. The videos are recorded in flash format, so you may need to enable flash on your browser in order to view the videos.
Direct link to videos - https://www.screencast.com/t/c73xusjul
Let us know if you have any questions.
Comment
-
Hello escobar63,
Historical data processing is forced to Calculate.OnBarClose. If you would like to calculate historical data OnEachTick or OnPriceChange, Tick Replay can be enabled. Please note that Tick Replay will not change the way orders are filled. (Orders will still fill based on the OHLC data the order is submitted to.) When using Tick Replay, you could add a single tick data series to the strategy and have orders submitted to the single tick data series for intra bar order fills.
Developing for Tick Replay - https://ninjatrader.com/support/help...ick_replay.htm
Please let us know if you have any additional questions.
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by NullPointStrategies, Yesterday, 05:17 AM
|
0 responses
65 views
0 likes
|
Last Post
|
||
|
Started by argusthome, 03-08-2026, 10:06 AM
|
0 responses
139 views
0 likes
|
Last Post
by argusthome
03-08-2026, 10:06 AM
|
||
|
Started by NabilKhattabi, 03-06-2026, 11:18 AM
|
0 responses
75 views
0 likes
|
Last Post
|
||
|
Started by Deep42, 03-06-2026, 12:28 AM
|
0 responses
45 views
0 likes
|
Last Post
by Deep42
03-06-2026, 12:28 AM
|
||
|
Started by TheRealMorford, 03-05-2026, 06:15 PM
|
0 responses
50 views
0 likes
|
Last Post
|

Comment