Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Optimizer and Walk forward question

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

    Optimizer and Walk forward question

    Hello NT support,
    If I enter in the "From" 01-01-09 in optimizer or WF and I enter in "Min. Bars required" 200, will the trading start on 01-01-09 and the needed bars will be collected from before or not.

    If not: In WF on the next optimization run will it start immidiatly?
    For example: First run 01-01-09 - 01-02-09, second run 02-02-09 - 01-03-09, on the second run will the trading start from 02-02-09?

    Regards,
    Baruch

    #2
    Baruch, this would be the same as in the backtest - it would wait for min bars from your set starting date and the create the first test - http://www.ninjatrader-support.com/H...AStrategy.html

    The next run should start immediately as the needed historical data to initialize the indicators properly is present then.

    Comment


      #3
      Hello Bertrand,
      Unfortunately you are wrong and on each run in WF on optimization and on test ninja waits for min. bars required again. I tested it with your MACrossOver strategy. If you put in min. bars required=200 you can see what happens. More so NT has a bug of starting to plot a MA even if its SMA(75) after 20 bars. The same is for SMA(10) it plots after 20 bars. Both are wrong!
      So my question is (probably support will not help so please some one else) how can I intercept and manipulate the "from" field?

      Regards,
      Baruch

      Comment


        #4
        Baruch, sorry you're correct - the unstable period would be 20 bars, but this is only for display - all NinjaTrader indicators would start calculating from bar 0, so your SMA 200 would need those bars to generate the first 'valid' average value. In your strategy you can set the min bars required high enough to avoid spurious trades because of this.

        Comment


          #5
          Bertrand hi,
          I know what to do, but I think that NT has to change it. Walk forward should work like this: Optimization period1 then from the end of it Back test period1, then Optimization period2 by advancing the "from" and "to" by back test period and so on.
          Now its load bars as in "min. bars required" then start Optimization1 then from the end of it load "min. bars required" again then start back test period1 and so on.
          So for example if I put in "min. bars required=100" and I want my test period to be 7 days, on each walk forward it will be 1-2 days less and not from optimization end. Because in futures the trading is 5 days a week this means that the actual test period is 3-4 days. It distorts the outcome.
          Please repair it or tell me how can I overcome this bug.

          Baruch

          Comment


            #6
            Baruch, I can confirm this works the same here on my end forward testing the ES 09-09 1 min with a min bars setting of 100, this would then also be applied before the individual walk forward test periods start trading. I'll forward your suggestion to development to make the walk forward testing more seamless, thanks!

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            633 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            364 views
            1 like
            Last Post Geovanny Suaza  
            Started by Mindset, 02-09-2026, 11:44 AM
            0 responses
            105 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Started by Geovanny Suaza, 02-02-2026, 12:30 PM
            0 responses
            567 views
            1 like
            Last Post Geovanny Suaza  
            Started by RFrosty, 01-28-2026, 06:49 PM
            0 responses
            568 views
            1 like
            Last Post RFrosty
            by RFrosty
             
            Working...
            X