Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Minimum Bars for Indicator Calculation

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

    Minimum Bars for Indicator Calculation

    Hi,

    Whenever I add an indicator to a Chart it only diplays it calculated in chart starting from bar 20. However, SMA of period lenght 3 should already exist since bar 2 (0,1,2). Is it being calculated but only displayed from bar 20 on or is there something I have to change in code to do it and display it ? I've already checked the native script for SMA indicator, but I couldn't find where the limitation for 21 bars minimum is...

    Thanks

    #2
    Hello agenor,

    Thanks for your post.

    What you are looking for is called "BarsRequired" which relates to the (display) plotting but not of the indicator calculation period. The BarsRequired default is 20. Here is a link to the help guide that discusses BarsRequired. http://www.ninjatrader.com/support/h...rsrequired.htm

    Please let me know if you have any further questions.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Hwop38, 05-04-2026, 07:02 PM
    0 responses
    173 views
    0 likes
    Last Post Hwop38
    by Hwop38
     
    Started by CaptainJack, 04-24-2026, 11:07 PM
    0 responses
    328 views
    0 likes
    Last Post CaptainJack  
    Started by Mindset, 04-21-2026, 06:46 AM
    0 responses
    252 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by M4ndoo, 04-20-2026, 05:21 PM
    0 responses
    354 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by M4ndoo, 04-19-2026, 05:54 PM
    0 responses
    181 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Working...
    X