Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Is there an indicator that can measure the correlation between two instruments?

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

    Is there an indicator that can measure the correlation between two instruments?

    I'd like a lower level indicator that would measure what is the correlation, in the mathematical sense of the word, between two data points, in this case between the price of two instruments, say the Emini S&P and the 30 year bond.

    The math for such correlation is :



    (from wiki)

    So, if there is some inverse correlation for those two instruments say for the last 3000 periods, it would show as -.89 for the current bar, as it compares the prices of those two instruments.

    Not asking anyone to code this for me, but could someone point me in the right direction--where to start?

    #2
    To get started for this project, you could check into the Correlation indicator work already shared here on the forums - http://www.ninjatrader.com/support/f...elation&desc=1

    All the best,

    Comment


      #3
      Forgot to thank you for this. Thanks

      Comment


        #4
        Hmmm, this works like a charm. I thought this would be difficult, but I'm off to an awesome start with this.

        This software is really powerful.

        Comment


          #5
          Thanks for the indicator. I have another question. I would like to study the correlation between an instrument and its indicator, e.g: 30 mins price chart with its 30 mins ADL.

          Here is my set up.

          Under the indicator window, I add
          ADL(symbol (30Min))

          After that, I add Correlation, under the parameters window,
          Symbol 2, I entered ADL("symbol" (30Min))
          Correlation Type, Pearson
          Period, 30
          PeriodPctChange, 1

          And the updated Indicator window shows
          ADL(symbol (30Min))
          Correlation(symbol,,Pearson,30,1)

          However, no correlation value is shown on the chart, can anyone help me?
          Thanks very much!

          Comment


            #6
            Thomas, as far as I'm aware on this custom study, you could really only create correlations between instruments.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            601 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            347 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
            559 views
            1 like
            Last Post Geovanny Suaza  
            Started by RFrosty, 01-28-2026, 06:49 PM
            0 responses
            558 views
            1 like
            Last Post RFrosty
            by RFrosty
             
            Working...
            X