Fast covariance and correlation matrix calculation.
1 2 3
A matrix with data. It has to be matrix, if it is data.frame for example the function does not turn it into a matrix.
If you want to center the data prior to applying the cross product of the mateix set this equal to TRUE, otherwise leave it NULL.
The calculations take place faster than the built-in functions
as the number of variables increases. For a few tens of variables. This is true if the
number of variables is high, say from 500 and above. The "cova" on the other hand is always
faster. For the "cova" in specific, we have an option to center the data prior to the cross product. This can be more stable if you
have many tens of thousands of rows due to numerical issues that can arise. It is sligtly slower.
For the correlation matrix we took the code from here
The covariance or the correlation matrix.
R implementation and documentation: Michail Tsagris <email@example.com> and Manos Papadakis <firstname.lastname@example.org>.
1 2 3 4 5
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.