Repairing a Correlation Matrix for Multivariate Normal Simulation
Summary
The document addresses a failure to simulate jointly distributed returns when the covariance matrix cannot be Cholesky-decomposed. The proposed remedy is to adjust the correlation matrix so it is positive definite. One suggested approach uses an eigenvalue decomposition: set negative eigenvalues to zero, reconstruct the matrix, and obtain a matrix square root from the decomposition for generating correlated draws.
The discussion offers a practical direction for preserving dependence across return buckets rather than splitting them and losing correlations. It does not provide implementation details, compare repair methods, or report simulation results. Setting negative eigenvalues to zero may also require attention to whether the reconstructed matrix still has the desired unit diagonal and whether the adjustment materially changes estimated correlations. The answer points to an external routine, but the document itself gives no validation or guidance on selecting among possible matrix adjustments.
Key ideas
- A covariance matrix that is not positive definite cannot be used directly with standard Cholesky-based simulation.
- Adjusting the correlation matrix to make it positive definite can enable joint return simulation.
- An eigenvalue decomposition can be used to remove negative eigenvalues and reconstruct a usable matrix.
- The matrix square root can be obtained from the eigenvalue decomposition instead of Cholesky.
Tags
Full text
# Multivariate normal when Cholesky decomp fails on Sigma
# Multivariate normal when Cholesky decomp fails on Sigma
I'm trying to do multivariate distributions of returns on buckets where all the returns are at least 0.6 correlated at a 95% confidence level. I have the buckets, but their Sigmas cannot be decomposed and my random number generator fails.
What alternatives do I have? If I break the buckets up into smaller ones, I lose the correlation in the simulation. Or am I completely wrong?
## Answer by will (score 1)
https://quant.stackexchange.com/a/27990
You need to adjust your correlation matrix such that it becomes positive definite.
There is an R routine that will do this for you - link.
Or, if you want to do it yourself, i believe the general method is to do an eigen value decomposition, set any negative eigenvalues to zero, and then reconstruct the original matrix.
If you're going to go down this route though, it works better to obtain your $\Sigma^\frac{1}{2}$ matrix using the EVD rather than cholesky.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.