MLAlgorithms icon indicating copy to clipboard operation
MLAlgorithms copied to clipboard

PCA: the calculation of proportion of vairance

Open keineahnung2345 opened this issue 7 years ago • 0 comments

In https://github.com/rushter/MLAlgorithms/blob/master/mla/pca.py#L48, the variance ratio of a component is calculated as the square of its eigenvalue divided by the sum of all squared eigenvalues. But according to https://stats.stackexchange.com/questions/31908/what-is-percentage-of-variance-in-pca, the proportion of variance of a component should be its eigenvector divided by the sum of all eigenvectors. Any ideas?

keineahnung2345 avatar Oct 09 '18 00:10 keineahnung2345