Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Renko Intraday Backtesting Problem

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

    Renko Intraday Backtesting Problem

    There is a major difference between intraday realtime and backtesting with renko bars.
    In backtesting the last bar of the day does only reflect the close of the day.
    So it could be that a trade that starts on close of the bar before will end as zero tick trade with no win or loss even if it has... See Screenshots.

    Is there anything I can do to resolve that issue?
    Attached Files

    #2
    starcd, the formation of the bars historical vs realtime could be unfortunately different, especially for those tick based types - the most accurate Renko backtesting would be seen when running a Market Replay simulation for the day, as then the intrabar formation would be known. For your backtest, I think a time filter in the strategy could help as well, to eliminate the entries close to the end of the session.

    Comment


      #3
      Thank's Bertrand,
      is there a way to set the time filter for entries in Renko at a fixed time e.g.190000? Because in Renko you don't know at what time the last correct bar will occure ...

      Comment


        #4
        Correct, you would not know as those types would not be time based - one thing you can do is adding a finer time based series, for example 1 minute one and then using those timestamps for your filtering via Times -

        Comment


          #5
          Thank's Bertrand,

          I looked at the example. But how can I compare a custom time e.g. 190000 with my second time based series?

          int a=190000;

          if (a < Times[1][0].Ticks) {
          ...
          }

          Comment


            #6
            You don't have to go to the ticks level, if you want to compare to an int convert the Times return with ToTime - http://www.ninjatrader.com/support/h...ightsub=ToTime

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            648 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            369 views
            1 like
            Last Post Geovanny Suaza  
            Started by Mindset, 02-09-2026, 11:44 AM
            0 responses
            108 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Started by Geovanny Suaza, 02-02-2026, 12:30 PM
            0 responses
            572 views
            1 like
            Last Post Geovanny Suaza  
            Started by RFrosty, 01-28-2026, 06:49 PM
            0 responses
            574 views
            1 like
            Last Post RFrosty
            by RFrosty
             
            Working...
            X