OPEN-SOURCE SCRIPT
Pearson Correlation Coefficient

Description: The Pearson Correlation Coefficient measures the strength and direction of the linear relationship between two data series. Its value ranges from -1 to +1, where:
This measure is widely used in technical analysis to assess the degree of correlation between two financial assets. The "Pearson Correlation (Manual Compare)" indicator allows users to manually select two assets and visually display their correlation relationship on a chart.
Features:
How to Select the Second Asset:
This indicator is ideal for traders looking to identify relationships and correlations between different financial assets to make informed trading decisions.
- +1 indicates a perfect positive linear correlation: as one asset increases, the other asset increases proportionally.
- 0 indicates no linear correlation: variations in one asset have no relation to variations in the other asset.
- -1 indicates a perfect negative linear correlation: as one asset increases, the other asset decreases proportionally.
This measure is widely used in technical analysis to assess the degree of correlation between two financial assets. The "Pearson Correlation (Manual Compare)" indicator allows users to manually select two assets and visually display their correlation relationship on a chart.
Features:
- Correlation Period: The time period used for calculating the correlation can be adjusted (default: 50).
- Comparison Asset: Users can select a secondary asset for comparison.
- Visual Plots: The chart includes reference lines for perfect correlations (+1 and -1) and strong correlations (+0.7 and -0.7).
- Alerts: Set alerts for when the correlation exceeds certain threshold values (e.g., +0.7 for strong positive correlation).
How to Select the Second Asset:
- Primary Asset Selection: The primary asset is the one you select for viewing on the chart. This can be done by simply opening the chart for the desired asset.
- Secondary Asset Selection: To select the secondary asset for comparison, use the input field labeled "Comparison Asset" in the script settings. You can manually enter the ticker symbol of the secondary asset you want to compare with the primary asset.
This indicator is ideal for traders looking to identify relationships and correlations between different financial assets to make informed trading decisions.
Script open-source
In pieno spirito TradingView, il creatore di questo script lo ha reso open-source, in modo che i trader possano esaminarlo e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricorda che la ripubblicazione del codice è soggetta al nostro Regolamento.
Declinazione di responsabilità
Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.
Script open-source
In pieno spirito TradingView, il creatore di questo script lo ha reso open-source, in modo che i trader possano esaminarlo e verificarne la funzionalità. Complimenti all'autore! Sebbene sia possibile utilizzarlo gratuitamente, ricorda che la ripubblicazione del codice è soggetta al nostro Regolamento.
Declinazione di responsabilità
Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.