Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Unable to get Backtest to work

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

    Unable to get Backtest to work

    Good morning

    I am trying to backtest a strategy and no trades are showing up on the chart and no trades are listed when I open up historical performance. I just downloaded the latest update to NT8 but that didn't help.


    #2
    Hello rexsole,

    Thanks for your post.

    Does your strategy skip historical processing? For example, are you checking if (State == State.Realtime) before calling your order entry methods? Or, are you calling if (State == State.Historical) return; within your strategy?

    If so, this would prevent the strategy from being able to be used in the Strategy Analyzer since historical processing is skipped.

    If this is not the case, please test running a backtest on the SampleMACrossOver strategy that comes default with NinjaTrader in the Strategy Analyzer.

    If you see no issues when running the SampleMACrossOver strategy, it is likely that there is an issue with the code of your strategy that is preventing orders from being placed. Debugging using prints would need to be done to determine what exactly in your strategy is causing the issue.

    Below is a link to a forum post that demonstrates how to use prints to understand behavior.
    https://ninjatrader.com/support/foru...121#post791121

    Let us know if we may assist further.
    <span class="name">Brandon H.</span><span class="title">NinjaTrader Customer Service</span><iframe name="sig" id="sigFrame" src="/support/forum/core/clientscript/Signature/signature.php" frameborder="0" border="0" cellspacing="0" style="border-style: none;width: 100%; height: 120px;"></iframe>

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    60 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    39 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    21 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    23 views
    0 likes
    Last Post TheRealMorford  
    Started by Mindset, 02-28-2026, 06:16 AM
    0 responses
    51 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Working...
    X