I am trying to use sklearn univariate feature selection to filter out irrelevant features:
ufs = feature_selection.SelectPercentile(feature_selection.f_classif, percentile = 60)
X_default_cvtrain = ufs.fit_transform( X_cvtrain, Y_cvtrain )
However, I get this warning:
UserWarning: Duplicate scores. Result may depend on feature ordering.
There are probably duplicate features, or you used a classification score for a regression task.
warn("Duplicate scores. Result may depend on feature ordering."
What does it mean? What is going on here?
Thanks.
It means that there are duplicate scores, so the selected features depend on the feature ordering. A probable cause is that you have duplicate features.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With