Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Strategy Session Template

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

    Strategy Session Template

    Ninjas,

    I noticed that an indicator assigned to a "regular" chart window produced different results when it was assigned to a strategy-analyzer-chart. I chose the "Default 24/7" template in the strategy time frame box and added the following line to my indicator code:

    Print(
    "Session-TimeZone: "+Bars.Session.TimeZoneInfo.Id+", SessionTemplate: "+Bars.Session.TemplateName);

    The output showed that my choice for the strategy session template obviously had no effect:

    Session-TimeZone: Central Standard Time, SessionTemplate: CME FX Futures RTH

    Could you clarify that?

    Best Regards,

    Ben

    #2
    Hello,

    Thank you for your forum post.

    This should not be the case as long as both chart and strategy analyzer have the same data.

    Please insure that the session templates and days back you are loading are the same in both charts to get the same results. Please right click on the chart and select data series and then check what session template you have in the chart or please specif one if you are on use instrument settings to Default 24/7 to be the same as your strategy analyzer.

    Then also make sure the days back are the same as the strategy analyzer.

    Once these both are checked you should see the same indicator values on historical data.

    Let me know if this is not the case.
    BrettNinjaTrader Product Management

    Comment


      #3
      two quick questions:
      1) is it possible to select a different default session template to run for every strategy?
      2) when running a live strategy, is there a way to adjust so that it only runs during market hours? (as not all stock market days close at 4pm)

      THX!

      Comment


        #4
        Hi Brett, thanks for the quick answer!

        What I've found out seems confusing to me: The session template which can be chosen in the backtest-panel is used to show the results, but NOT to calculate the indicators/strategy. The only way to change what's being calculated is to set the respective session template in the instrument settings. This template is NOT used for showing the results, only for calculation.
        I expected it to be the other way round..?!

        Comment


          #5
          What I do on a regular basis is resave with a new name the indicators used in my strategies. This accomplishes 3 things:

          1. I can change defaults, what is dispalyed, what is calculated etc on the indicator itself, and be sure what is used in the strategy is what I am 'eyeballing'.
          2. If I happen to import an indicator with someone else's sample code I can be fairly certain it wont affect my strategy by overwriting an indicator.
          3. If I export a strategy for someone to review, it wont overwrite their own indicators and they can be certain they see what I see.

          I think it is worth the time.

          Jon

          Comment


            #6
            nightriderx, it is possible to select a different template for every strategy. It is just the session template setting used when starting the strategy. For your second question, yes, you'll just have to select the appropriate session template.

            traderhh, the session template selected in the backtest panel (in the time frame settings section) is what is used for both the actual backtest as well as the results. There should be no difference.

            Trader.Jon, thanks for the information.
            AustinNinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            598 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            343 views
            1 like
            Last Post Geovanny Suaza  
            Started by Mindset, 02-09-2026, 11:44 AM
            0 responses
            103 views
            0 likes
            Last Post Mindset
            by Mindset
             
            Started by Geovanny Suaza, 02-02-2026, 12:30 PM
            0 responses
            556 views
            1 like
            Last Post Geovanny Suaza  
            Started by RFrosty, 01-28-2026, 06:49 PM
            0 responses
            555 views
            1 like
            Last Post RFrosty
            by RFrosty
             
            Working...
            X