Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

NT8 if (BackTestMode == BackTestMode.WalkForward)

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

    NT8 if (BackTestMode == BackTestMode.WalkForward)

    Hello,

    In NT7 I would use the following code to extract the trade results from WalkForwardAnalysis to a text file that allowed me to graph the complete PNL of an entire WFO execution that spanned many months.

    I am converting from NT7 to NT8 and hoped you could tell me what the NT8 expression would be that I could place in if(State==State.Terminated).

    In NT7 I used...
    protected override void OnTermination()
    {
    if (BackTestMode == BackTestMode.WalkForward) { vExtractPerformanceTrades_ToFile(); }
    }

    I can`t find any references to BackTestMode in NT8 help or an equivalent property.

    Can you please tell me if there is a way for a strategy to know if its being executed in WalkForward mode ?

    Please let me know ?

    #2
    This is an undocumented property and subject to change/break in future releases, but you may try:

    Category == Category.Backtest
    Category == Category.WalkForward
    Category == Category.NinjaScript // normal
    MatthewNinjaTrader Product Management

    Comment

    Latest Posts

    Collapse

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