C.W.K.
Stream
Lesson 03 of 06 · published

Covariance, correlation — friends shaking together

~35 min · covariance, correlation

Level 0Numeracy Apprentice
0 XP0/68 lessons0/14 achievements
0/100 XP to next level100 XP to go0% complete

Two stocks, shaking together

If you hold one stock, σ tells you its shake. But what if you hold two? Or twenty? The total shake of the portfolio depends not just on each individual σ — it depends on how the stocks shake together.

Two extremes:

  • If two stocks always move in lockstep (one up, the other up; one down, the other down), holding both gives you no risk reduction. Their shakes amplify each other.
  • If two stocks move opposite (one up, the other down), holding both cancels out some of the shake. Combined shake is less than each individual.

Most real stocks fall somewhere in between. The number that captures "how together they shake" is covariance. Its more readable cousin is correlation.

Covariance — the rough version

Covariance between two return streams measures whether they move together (positive covariance), opposite (negative), or independently (near zero). The math is essentially: for each time period, compute (A's return − A's mean) × (B's return − B's mean), then average those products across all periods.

The product is positive when both deviate the same direction (both above average, or both below). It's negative when they deviate opposite directions. Average it: positive average → they tend to move together. Negative → they tend to move opposite. Zero → uncorrelated.

The problem with covariance: its units are return-squared. So the magnitude depends on the scale of the returns. A covariance of 0.0001 might be huge or tiny depending on the σ of each asset. Hard to interpret.

Correlation — covariance, normalized

Correlation fixes that. It's covariance divided by the product of the two standard deviations:

This always lands between −1 and +1, no matter what units the returns are in:

  • ρ = +1: perfectly positive — they move identically
  • ρ = 0: uncorrelated — knowing one tells you nothing about the other
  • ρ = −1: perfectly negative — opposite moves, every time

Real-world examples:

  • Two large US tech stocks (AAPL and MSFT, say): ρ ≈ 0.7 — most of the time they move similarly
  • US stocks vs. US Treasury bonds: ρ ≈ −0.2 to +0.3 (varies; sometimes they hedge each other, sometimes they don't)
  • Gold vs. US stocks: often near zero or slightly negative
  • Two random small-cap stocks in different sectors: ρ ≈ 0.3-0.5

Why this matters

The portfolio's combined volatility depends on both the individual σ's and the correlation between them. Two perfectly correlated stocks (ρ = 1) give the same combined σ as a single one — no diversification benefit. Two anticorrelated stocks (ρ = −1) can in theory cancel each other's shake to zero. Most realistic portfolios live somewhere in between, and the magic of diversification (next lesson) lives in that "in between."

Correlation is also a polymorphic kid of the "shake" base class — it tells you whether two shakes happen together. We'll use it constantly through Tracks 9 and 10.

The takeaway

Covariance asks "do they move together?" Correlation is the same question, normalized to [−1, +1] for easy reading. Two stocks with ρ near +1 don't really diversify each other; ρ near 0 or negative does. This is the seed of why portfolio math is more than just averaging individual stocks.

Exercise

  1. If two stocks both have σ = 20% and they're perfectly correlated (ρ = 1), what's the σ of holding 50/50 of them? (Hint: same σ — no diversification benefit.)
  2. If those same stocks are uncorrelated (ρ = 0), the math gives σ_portfolio = 20% / √2 ≈ 14.1%. By how many percentage points did the σ shrink?
  3. If they were anticorrelated (ρ = −1), what's the σ of the 50/50 portfolio? (Hint: in theory zero — they cancel.)
  4. Which scenario is the most realistic in real markets, and why?

Progress

Progress is local-only — sign in to sync across devices.
Spotted a bug or have feedback on this page?Report an Issue
💛 by Ttoriwarm

Comments 0

🔔 Reply notifications (sign in)
Sign inPlease sign in to comment.

No comments yet — be the first.