Lesson 15 of 15

Risk Parity Weights

Risk Parity

Risk parity portfolios allocate capital so that each asset contributes equally to total portfolio risk.

For the simple case (ignoring correlations), each asset's risk contribution is proportional to w_i × σ_i. Setting these equal:

wiσi=wjσji,jw_i \cdot \sigma_i = w_j \cdot \sigma_j \quad \forall i, j

Two-Asset Risk Parity

For two assets with volatilities σ₁ and σ₂:

w1=σ2σ1+σ2,w2=σ1σ1+σ2w_1 = \frac{\sigma_2}{\sigma_1 + \sigma_2}, \quad w_2 = \frac{\sigma_1}{\sigma_1 + \sigma_2}

This allocates more weight to the less volatile asset.

N-Asset Risk Parity (Inverse Volatility)

For N assets, the inverse volatility weights are:

wi=1/σij1/σjw_i = \frac{1/\sigma_i}{\sum_j 1/\sigma_j}

Risk Parity vs. Minimum Variance

Risk parity and minimum variance are both portfolio construction approaches, but they differ fundamentally:

  • Minimum variance minimizes total portfolio variance, which can lead to highly concentrated portfolios (all weight in the lowest-vol asset)
  • Risk parity ensures each asset contributes equally to risk, leading to more diversified portfolios

Risk parity ignores expected returns entirely and focuses on balanced risk contribution. Bridgewater's "All Weather" fund popularized this approach.

Verifying Equal Risk Contribution

For inverse-volatility weights, each asset's marginal risk contribution is w_i * σ_i. If risk parity is correct, all these products should be equal:

w_i * sigma_i == w_j * sigma_j  for all i, j

Your Task

Implement:

  • risk_parity_2(s1, s2) — returns a tuple (w1, w2) of risk parity weights for two assets, each rounded to 4 decimal places
  • risk_parity_n(sigmas) — returns a list of inverse volatility weights for N assets, each rounded to 4 decimal places
Python runtime loading...
Loading...
Click "Run" to execute your code.