Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Can NT do "intra-bar" backtesting??

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Can NT do "intra-bar" backtesting??

    Hello,

    If we write a backtest code in NT that says: Place a Buy order "at market" price if the current price exceeds the previous bar's high price by 1 tick. We also want to run this backtest on "daily" bars (Candlesticks). Let's assume yesterday's daily bar high price was 1.3542 (say on the Euro FX futures). Lets also assume that today's bar (the actual entry bar) high was 1.3630 and today's bar low was 1.3498, and hence today there was a break of yesterday's bar high price.

    Our question for NinjaTrader support staff is as follows: In the NT backtest report will today's BUY entry order be reported at exactly 1.3543 ?? (note that this entry represents a 1 tick break of yesterdays high price).

    In the above example, at what price will NT's backtesting engine report the BUY entry at exactly? We need NT staff to tell us the exact entry price that we would see reported in the backtest performance report??

    Thank you in advance.

    Kind regards,

    Rod

    #2
    Hi Rod, a market order would be filled at the next bar open, as it's essentially the first tradable price after the condition hit - you can however add finer series to your strategy to simulate getting intrabar fills :

    You can submit orders to different Bars objects. This allows you the flexibility of submitting orders to different timeframes. Like in live trading, taking entry conditions from a 5min chart means executing your order as soon as possible instead of waiting until the next 5min bar starts building. You can achieve this by

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    68 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    38 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    62 views
    1 like
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    62 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    53 views
    0 likes
    Last Post CarlTrading  
    Working...
    X