Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How to call another indicator

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

    How to call another indicator

    I would like to develop an indicator that uses the values of the "Swing (High/Low)" array or output. The Swing indicator tracks the historical values of pivot highs and lows within a given period and lookback timeframe. I know VB programming, but I don't know C# syntax very well. What is the method to call the Swing indicator to get the current value of the High and Low pivots from the OnBarUpdate code in my new indicator?

    Thank you!
    Bryan
    cassb
    NinjaTrader Ecosystem Vendor - Logical Forex

    #2
    Please ensure you are using NT6.5. In 6.5 we have exposed the Swing plot values for you to call.

    Code:
    Swing(5).SwingHigh[0];
    Swing(5).SwingLow[0];
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      Excellent, thanks Josh. I have v6.0 still -- I thought 6.5 was still in beta?

      Sorry to bug people about C# syntax...still learning. ;-)

      Bryan
      cassb
      NinjaTrader Ecosystem Vendor - Logical Forex

      Comment


        #4
        Yes, 6.5 is still in beta.
        RayNinjaTrader Customer Service

        Comment


          #5
          Originally posted by Josh View Post
          Please ensure you are using NT6.5. In 6.5 we have exposed the Swing plot values for you to call.

          Code:
          Swing(5).SwingHigh[0];
          Swing(5).SwingLow[0];

          Just a question, if you want the most recent Swing High you use :
          Swing(5).SwingHigh[0] but if there's a way to obtain the prior Swing value.

          For example If I use the index [1] what value I obtain?

          Regards

          Comment


            #6
            An index of [1] will return the value of the swing high 1 bar ago. This could be the current swing high, or the prior one. To determine this, you would need to use:


            Swing(int strength).SwingHighBar(int barsAgo, int instance, int lookBackPeriod)

            this returns the number of bars ago a swing high pivot was found. Please see the detailed Help Guide in 6.5 for the Swing indicator.
            RayNinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Anthony_0709, Today, 01:29 PM
            2 responses
            6 views
            0 likes
            Last Post Anthony_0709  
            Started by kenbun, Today, 12:21 PM
            0 responses
            9 views
            0 likes
            Last Post kenbun
            by kenbun
             
            Started by WNorton, Today, 11:23 AM
            1 response
            13 views
            0 likes
            Last Post NinjaTrader_Spencer  
            Started by stafe, Today, 10:43 AM
            0 responses
            12 views
            0 likes
            Last Post stafe
            by stafe
             
            Started by UltraNIX, Today, 09:13 AM
            3 responses
            18 views
            0 likes
            Last Post UltraNIX  
            Working...
            X