Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

bars required lookback

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

    bars required lookback

    BarsRequired
    Print this Topic Previous pageReturn to chapter overviewNext page


    Definition
    The number of bars on a chart required before the indicator plots. This is NOT the same as a minimum number of bars required to calculate the indicator values.
    from the help.

    I think i need this other one it talks about. I need to find out how many bars are required. Like when I set up in the market anaylzer 5 minute chart 1000 bars. I need to get this 1000 number - the lookback number.

    How do I access that?

    #2
    Originally posted by NinjaCustomer View Post
    from the help.

    I think i need this other one it talks about. I need to find out how many bars are required. Like when I set up in the market anaylzer 5 minute chart 1000 bars. I need to get this 1000 number - the lookback number.

    How do I access that?
    You specify the number of bars required using the BarsRequired property. If you have not overridden it, then it is the default "20"? Did I misunderstand your question?

    Comment


      #3
      Hello NinjaCustomer,

      Thank you for your post.

      The Maximum Number Of Bars To Look Back actually only contains two values; either Infinite or TwoHundredAndFiftySix.

      Information can be found at the following link: http://www.ninjatrader.com/support/h...rslookback.htm

      Comment


        #4
        actually I came across this number 20 in my debug output for BarsRequired

        but actually this is output of an indicator running in a M.A. with a "# of bars to look back" of 1000 in the dialog.

        I need to grab this 1000 in my code, not the 20 I'm getting.

        Is there a way to do that?

        Comment


          #5
          Hello NinjaCustomer,

          Thank you for your response.

          There is no supported method or function for this property, and I cannot find any unsupported code to pull this property either.

          Comment


            #6
            ok, thanks

            Comment


              #7
              Originally posted by NinjaCustomer View Post
              actually I came across this number 20 in my debug output for BarsRequired

              but actually this is output of an indicator running in a M.A. with a "# of bars to look back" of 1000 in the dialog.

              I need to grab this 1000 in my code, not the 20 I'm getting.

              Is there a way to do that?
              Can you clarify your problem?

              You said you had a custom MA indicator with a period (bars to look back) of 1000.
              And in another indicator you are creating, you want to reference this number, right?

              Thanks.
              Pi
              ninZa
              NinjaTrader Ecosystem Vendor - ninZa.co

              Comment


                #8
                sorry I was lazy typing (this keyboard is a bit small).. M.A. not MA , Market Analyzer not Moving Average.

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by samish18, 04-17-2024, 08:57 AM
                27 responses
                116 views
                0 likes
                Last Post NinjaTrader_BrandonH  
                Started by ETFVoyageur, 04-30-2024, 02:04 PM
                7 responses
                43 views
                0 likes
                Last Post eDanny
                by eDanny
                 
                Started by f.saeidi, Today, 07:07 AM
                5 responses
                15 views
                0 likes
                Last Post NinjaTrader_ChelseaB  
                Started by Creamers, 04-27-2024, 05:32 AM
                9 responses
                60 views
                0 likes
                Last Post Creamers  
                Started by cmtjoancolmenero, 04-29-2024, 03:40 PM
                19 responses
                60 views
                0 likes
                Last Post NinjaTrader_Jesse  
                Working...
                X