JingweiToo / Wrapper-Feature-Selection-Toolbox-Python

This toolbox offers 13 wrapper feature selection methods (PSO, GA, GWO, HHO, BA, WOA, and etc.) with examples. It is simple and easy to implement.
BSD 3-Clause "New" or "Revised" License
249 stars 69 forks source link

regression problem #13

Closed Mohammedsaied89 closed 3 years ago

Mohammedsaied89 commented 3 years ago

when i changed knn with linear regression and changed accuracy with r2 and mean squared error i got this error ( ValueError: The least populated class in y has only 1 member, which is too few. The minimum number of groups for any class cannot be less than 2.) my dataset consist of 5 input and 1 output and all numerical

JingweiToo commented 3 years ago

I think it is your dataset issue. Your label might be seriously imbalanced. Change the stratified holdout to normal holdout.