BacktestRookies

Correlate 3 - Correlation Indicator

The code in contains a simple correlation indicator that can be used as an alternative to Tradingview’s built-in “Correlation Coefficient” indicator. The indicator allows users to correlate up to 3 separate instruments on the same subplot. This allows you, for example, to easily see the correlation of your instrument with stocks, bonds and FX. Alternatively, a user can also see the correlation with sector, industry peers or any other data available in Tradingview.

Features
Ta bort från favoritskript Lägg till som favoritskript

Kommentarer

hey, i was trying to find the correlation between 3 different ETF's. i'm using the same code you have above, but when i try to get the three i'm interested in (SPY, HYG, JNK), it's not working.

I notice you're using LSE and OANDA -- the 3 i'm interested in are on ARCA, not sure if that changes everything. Any thoughts?

inst1 = input(defval='ARCA:SPY', type=symbol, title='ETF')
inst2 = input(defval='ARCA:HYG', type=symbol, title='ETF')
inst3 = input(defval='ARCA:JNK', type=symbol, title='ETF')

i simply get an error.
Svara
Hem Aktie-screener Forex-screener Krypto-screener Ekonomisk kalender Hur det fungerar Diagramfunktioner Priser Tipsa en vän Ordningsregler Hjälpcenter Webbsidor och mäklarlösningar Widgets Diagramlösningar Lightweight Charting Library Blogg och nyheter Twitter
Profil Profilinställningar Konto och fakturering Hänvisade vänner Mynt Mina kölappar Hjälpcenter Publicerade idéer Följare Följer Privata meddelanden Chatt Logga ut