Correlation Analysis
Correlation analysis is a statistical method used to evaluate the strength and direction of the relationship between two quantitative variables.
Types: 1. Positive Correlation (r > 0). 2. Negative Correlation (r < 0). 3. No Correlation (r = 0). Coefficients: Pearson (Linear), Spearman (Ordinal/Non-linear), Kendall's Tau. Use Cases: Investment portfolios, machine learning feature selection, medical research, weather prediction.
graph LR
Center["Correlation Analysis"]:::main
classDef main fill:#7c3aed,stroke:#8b5cf6,stroke-width:2px,color:white,font-weight:bold,rx:5,ry:5;
classDef pre fill:#0f172a,stroke:#3b82f6,color:#94a3b8,rx:5,ry:5;
classDef child fill:#0f172a,stroke:#10b981,color:#94a3b8,rx:5,ry:5;
classDef related fill:#0f172a,stroke:#8b5cf6,stroke-dasharray: 5 5,color:#94a3b8,rx:5,ry:5;
linkStyle default stroke:#4b5563,stroke-width:2px;
🧒 Explain Like I'm 5
Correlation is like looking at two dancers. If they always step left together and turn right together, they have a 'High Positive Correlation'. If one always goes left when the other goes right, that's 'Negative Correlation'. If they are just doing their own thing and ignore each other, the correlation is zero. Knowing this helps you predict what one dancer might do by watching the other.
🤓 Expert Deep Dive
Technically, the 'Pearson Product-Moment Correlation' measures the degree of linear relationship between two variables. If the relationship is non-linear but still consistent, 'Spearman’s Rank Correlation' (which uses data rankings rather than raw values) is more appropriate. A major pitfall in data analysis is 'Spurious Correlation'—where two variables appear related by chance or due to a hidden third variable (e.g., ice cream sales and shark attacks both increase in summer due to heat, not because ice cream causes shark attacks). In quantitative trading (Quant), 'Pair Trading' strategies rely on finding assets with historically high correlation that have temporarily diverged. High correlation between all assets in a portfolio during a 'Market Crash' is known as 'Systemic Risk', where diversification fails because everything drops simultaneously.