Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Retrieve exact execution time for backtest limit orders

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

    Retrieve exact execution time for backtest limit orders

    Hi NT team,

    I have a multi-time series intraday trading strategy which I am backtesting. For example I run the strategy on daily bars, but add 60minutes bars for advanced trade logic. The 60 minute bars create enter limit orders. When I now try to retrieve the exact execution time with execution.ToString(), NT will only always give me the time of the 60 minute bar, but not the actual execution time with theoretically available minute data. I use minute data, and I have also tried adding a 1 minute bar and tried accessing the most recent time information using Times[2][0] in OnExecution(), I tried with calculate on bar close = false, etc. No success...

    Is it possible at all to have more granular information when exactly a limit order was filled in backtests?

    Thank you
    whotookmynickname

    #2
    whotookmynickname, when you say you add in 1 minute as well, do you then actually submit the orders to this BarsInProgress for the fills?

    EnterLongLimit(int barsInProgressIndex, bool liveUntilCancelled, int quantity, double limitPrice, string signalName)



    Sounds to me like this is the step you're missing here...

    Comment


      #3
      Retrieve exact execution time for backtest limit orders

      Hi Bertrand

      I know that this is what I can do, but I would have to rewrite my code and I do not want to actually submit/manage my orders on a 1-minute level, but rather only retrieve the exact time for analysis purposes.

      Also, let's say I had tick data and I used 1-minute data for BIP/order management I would still not have the "real" trade time but just the last time of the 1-minute BIP.

      So is it fair to assume that NT cannot determine the actual fill time for backtests? Or is there a workaround other than submitting/managing the orders on a 1-minute level?

      whotookmynickname

      Comment


        #4
        Correct, there would be no other workaround - the fill resolution is determined by the series you submit to and thus could be controlled this way.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        558 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        324 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        101 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        545 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        547 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X