Variance of portfolio return

Variance of a portfolio measures the dispersion of average returns of a portfolio from its mean. It tells us about the total risk of the portfolio. It is calculated based on the individual variances of the portfolio investments and their mutual correlation.

Variance of individual assets

Variance of an individual investment is calculated using the following steps:

  • Calculate the arithmetic mean (i.e. average) of the asset returns
  • Find out difference between each return value from the mean and square it
  • Sum all the squared deviations and divided it by total number of observations

Let us say an investment generated a return of 2%, 3%, 4% in three months. The arithmetic mean of returns equals 3%:

μ =2% + 3% + 4%= 3%

The sum of squared deviations is 0.02%:

Sum of Squared Deviations
= (2% − 3%)2 + (3% − 3%)2 + (4% − 3%)2
= 0.02%

The variance of individual investment equals 0.0067%

σ2 =0.02%= 0.0067%

In case of a portfolio, we need to work out the variance using the individual variance of each investment. However, because different investments have less than perfect correlation, we must account for the covariances between different investments. The variance of a portfolio is less than the weighted average of the variance of individual investments due to their less than perfect correlation.

Calculation of variance of a portfolio

For calculation of variance of a portfolio, we need a matrix of mutual correlation of all the constituent assets of the portfolio (called correlation matrix). The exact formula differs depending on the number of assets in the portfolio.

In case of a two-asset portfolio, we can work out portfolio variance as follows:

σ2 = w12σ12 + w22σ22 + 2w1w2Covariance(1,2)

Where w1 is weight of first asset, w2 is weight of second asset, σ12 is variance of first asset and σ22 is variance of second asset and Covariance(1,2) shows covariance of the two assets. Since covariance equals the product of correlation coefficient and standard deviation of each asset, we can rewrite the above equation as follows:

σ2 = w12σ12 + w22σ22 + 2w1w2σ1σ2ρ

ρ is the correlation coefficient of returns of first and second asset.

For a three-asset portfolio, the variance formula is as follows:

= w12σ12 + w22σ22 + w32σ32
+ 2w1w2σ1σ2ρ1,2
+ 2w2w3σ2σ3ρ2,3
+ 2w1w3σ1σ3ρ1,3

Similarly, we can create a function for a portfolio with n number of assets where there are n number of terms of products of squared asset weighted and variances and n(n-1)/2 number of covariance terms.

A better way is to use the variance-covariance matrix to find portfolio variance.


Illustrate diversification benefits in a portfolio of three investments, a stock A, a bond B, and a real estate asset C. The assets weights are 20%, 35% and 45% respectively, their standard deviations are 2.3%, 3.5% and 4%, the correlation coefficient between A and B is 0.6, between A and C is 0.8 and between B and C is 0.5:

We need to work out the variance of the portfolio as follows:

= 20%2 × 2.3%2 + 35%2 × 3.5%2 + 45%2 × 4%2
+ 2 × 20% × 35% × 2.3% × 3.5% × 0.6
+ 2 × 35% × 45% × 3.5% × 4% × 0.5
+ 2 × 20% × 45% × 2.3% × 4% × 0.8
= 0.0916%

The volatility is best measured using standard deviation which can be calculated as follows:

σ = (σ2)1/2 = (0.0916%)1/2 = 3.03%

If the assets had perfect correlation and they move together, the portfolio variance and standard deviation would have been 0.1215% and 3.49%. But since different assets rarely have perfect correlation diversification is useful. A good test to see if addition of an asset will result in diversification benefit or not is to compare the Sharpe ratio before addition and after addition.

by Obaidullah Jan, ACA, CFA and last modified on is a free educational website; of students, by students, and for students. You are welcome to learn a range of topics from accounting, economics, finance and more. We hope you like the work that has been done, and if you have any suggestions, your feedback is highly valuable. Let's connect!

Copyright © 2010-2024