generated from scikit-learn-contrib/project-template
-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incorrect implementation of Participation Ratio #14
Comments
I couldn't find the original reference of participation ratio, maybe you know it ? It seems usual practice to refer to PR of eigenvalues of the covariance matrix. But I can add an option to return eigenvalues without centering if you need it for your application, thanks for the suggestion! |
I also double checked, and I'm not sure either. Regardless, an optional flag would be awesome, thank you! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I just noticed what I think might be a problem with your implementation of Participation Ratio!
Suppose one is given a matrix
X
with shape(num samples, num features)
. The PR is given bysquare(sum(eigenvalues)) / sum(square(eigenvalues))
ofX^T X
, but the implementation usesPCA
.scikit-dimension/skdim/id/_PCA.py
Line 149 in 1ddee0f
This is incorrect because
PCA
first demeans the data. I don't think that's correct.The text was updated successfully, but these errors were encountered: