Skip to content
All library documents

Computing Long-Short Portfolio Variance with Cash Holdings

Article Quant Q&A · Author: Stanford Wong

Summary

The document explains how to calculate variance for a portfolio that is long one stock, short another, and holds the remaining capital in cash. Its example uses weights of 1.0 in stock A and -0.5 in stock B, with cash completing the total portfolio weight. Since cash is assumed to have zero volatility and zero covariance with the risky assets, it contributes no variance terms.

The resulting variance is determined by the two stocks’ variances and their covariance, weighted by their long and short positions. The weights on risky assets do not need to sum to one when the omitted allocation is represented by cash; the full portfolio weights, including cash, sum to one. This result relies on cash having constant returns over the measurement period. The note does not address financing costs, borrowing fees, changing cash balances, or other practical features of short positions.

Key ideas

  • Portfolio weights sum to one when cash is included as an asset.
  • A zero-volatility cash position adds no variance or covariance terms.
  • Long and short stock weights enter the portfolio variance formula with their signs.
  • The variance calculation depends on the risky assets’ variances and covariance.

Tags

Full text
# How to compute the variance of a Long-Short Equity Portfolio?


# How to compute the variance of a Long-Short Equity Portfolio?












I am calculating the historical portfolio variance of various long-short equity portfolios. For simplicity, assume the portfolio is long stock A with weight 1.0 and short stock B with weight -0.5. So cash/risk free is 0.5 for an overall portfolio weight of 1.0.

Since $\sigma^2_\text{risk free} = 0$ and $\sigma^2_{\text{risk free}, X} = 0$, I reduce the portfolio to a 2x2 covariance matrix for A and B with weights [1.0, -0.5]. However, the weights don't total 1 for this portfolio and I thought the weights have to total one?

Am I thinking about this correctly?

## Answer by RRL (score 5, accepted)

https://quant.stackexchange.com/a/32647

We have weights $w_A$, $w_B$ and $w_C = 1 - w_A - w_B$ that sum to $1$.

With de-meaned returns $r_A$, $r_B$, and $r_C$, the portfolio variance is $$E\{[w_A r_A + w_B r_B + (1 - w_A - w_B)r_C]^2 \} = w_A^2\sigma_A^2 + w_B^2\sigma_B^2 + 2 w_A w_B\rho_{AB}\sigma_A \sigma_B,$$

assuming the cash volatility $\sigma_C$ is zero.

Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.