Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

NT7B9 Add(Indicator) Strategy not placing historical trades

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

    NT7B9 Add(Indicator) Strategy not placing historical trades

    I was running into issues testing a strategy that Adds its own indicators in the Initialize method as it would not take historical trades. I could only get it to trade if I commented out the Add(Indicator) statements. I was able to replicate this using the SampleMACrossOver strategy in NT7B9. Can NT Support confirm this? I assume this is related to the multi-timeframe issue.

    Thanks,

    Whitmark
    whitmark
    NinjaTrader Ecosystem Vendor - Whitmark Development

    #2
    I have been experiencing the same problem, and it is totally repeatable.

    I have found that if the indicator is added in the Initialize method, and I also use that same indicator in my in my strategy code (i.e. in OnBarUpdate) like this;
    myVariable = ADX(10)[0]
    then myVariable is always 0 for historical bars. Realtime bars will have the correct value.
    As soon as you comment out the Add indicator in the Initialize, then myVariable will return the correct values for Historical bars as well as real time.
    p.s. I am NOT using multi-series in my indicator or strategy.
    Last edited by astrolobe; 02-16-2010, 05:30 PM.

    Comment


      #3
      Astrolab, thanks for confirming. Yes, it only seems to impact historical bars as the realtime bars will generate trades and, as you point out, no need to have a secondary timeframe for this to occur.

      Whitmark
      whitmark
      NinjaTrader Ecosystem Vendor - Whitmark Development

      Comment


        #4
        yes, unfortunately this issue was introduced with B9 and will be fixed again with next update. Sorry for the inconvenience.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        612 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        355 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
        561 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        564 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X