Tagged Questions
13
votes
3answers
3k views
What is the best way to “fix” a covariance matrix that is not positive semi-definite?
I have a sample covariance matrix of S&P 500 security returns where the smallest k-th eigenvalues are negative and quite small (reflecting noise and some high correlations in the matrix).
I am ...
3
votes
2answers
605 views
Covariance for arbitrarily large portfolios
I am implementing a method in Java to calculate the variance, covariance, and value at risk for a portfolio, which should be flexible for use with any number of assets in a portfolio. I am struggling ...