File Exchange

image thumbnail

Matrix Decomposition

version 1.7 (903 KB) by

Positive definite correlation matrix based on spectral decomposition. Now both for .m, C and Mex

11 Downloads

Updated

View License

Matrix decomposition using, e.g. the Cholesky decomposition requires the correlation matrix to be positive definite. That is, the eigenvalues must all be positive. In finance, this is rarely the case, and one often observes negative eigenvalues, or zero eigenvalues. These two functions do essentially the same thing. One adjusts only the <= 0 eigenvalues, while the other adjusts those eigenvalues, but then also increases the other non-negative eigenvalues to compensate for the higher 'weight' given to the smaller eigenvalues.

Comments and Ratings (5)

Ashim

Ashim (view profile)

The Coherence results in Coherence of 1.2 maximum, which is not possible, could you recommend what may be the problem?

Lorenzo

Hi,

[Eig_Vec,~]=eig(Corr_Mat) this give me the following error:

|
Error: Unbalanced or unexpected parenthesis or bracket.

But I cannot figure out why. Do you have any idea? Thanks

Aleksander

The latest submission includes the function written in the C programming language, as well as a MEX implementation, thus providing significant speed and memory enhancements.

Aleksander

Does the trick!

Marco

Marco (view profile)

Very useful and efficient functions. Thanks to the willing and gentle author for the prompt and clear help.

Updates

1.7

This update includes the program in C programming code, as well as a MEX implementation, providing potentially significant speed and memory handling enhancements.

1.6

Added screenshot

1.3

Updated description

1.2

Removed one function

MATLAB Release
MATLAB 7.12 (R2011a)

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video