Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

nt not displaying range for current session.

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

    nt not displaying range for current session.




    people with nt,



    i have created a simple indicator that should calculate and display the range as high - low. this seems to work well for historical data. however, for the current session, nt will display n/a. once the session is over, the range will be displayed correctly. it should be obvious that the current session is always the most important data point so i want to know how can this be fixed so the range for all dates, including the current session can be correctly displayed.



    also, ¿how can i calculate the range as high - low but only for the data between 09:30 and 16:00 eastern yankee time? please provide a working sample of the code required.
    Last edited by rtwave; 12-02-2023, 01:32 PM.

    #2
    Hello rtwave,

    Thanks for your post.

    Please share a simple test script demonstrating how you are calculating the High[0] - Low[0] and it displaying as N/A so we may accurately assist.

    You could create a Time Filter in your script if you want to limit logic in your script to occur only during a certain time. Within that Time Filter condition you could calculate High[0]-Low[0] to get the range of the bar.

    See the 'how to create time filters' section' of this help guide page detailing how to create Time Filters: https://ninjatrader.com/support/help...on_builder.htm

    And, see this reference sample: https://ninjatrader.com/support/help...to_limit_t.htm
    <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


      #3


      people with nt,



      this is the situation i'm referring to:


      Click image for larger version

Name:	20231205 nt malfunction 0001.jpg
Views:	103
Size:	157.0 KB
ID:	1280985




      i'm using exactly the range indicator that is part of the nt platform.



      and for other indicators i have created that include the same calculation of high0 - low0 the same malfunction will be observed.



      on the subject of time filters, i'm pretty sure that it will not be possible to apply time filters to daily data. however, i have found the different session templates and those could possibly work.

      Comment


        #4
        Hello rtwave,

        Thanks for your notes.

        If you are hovering you mouse over the currently forming candle on the chart and see n/a reported in the Data Box, this is because the indicator has not plotted on that bar yet.

        When Calculate.OnBarClose is used, the indicator plot will display up to the last closed bar.

        To have your indicator plot values on the currently forming bar, you could set the indicator's Calculate mode to Calculate.OnPriceChange or Calculate.OnEachTick.

        See this help guide page for more information about Calculate: https://ninjatrader.com/support/help.../calculate.htm
        <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 Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        571 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        331 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        101 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        549 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        549 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X