You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Sklearn RFECV doesn't work with categorial columns in Catboost #17338
I get the follwing error: ValueError: could not convert string to float: 'W'
'W' is a value of my first categorial column. Although i told catboost which columns are categorial through the cat_features parameter (in my case i passed it as list of labels), it expected a numerical column. Is this the expected behaviour? Or do i have to integer encode the categories in this use case?
If i call just model.fit(X,y), it works without problems.
You need to encode the categorical features with a ColumnTransformer and an OrdinalEncoder or OneHotEncoder. Scikit-learn does not handle natively the categorical data.
CatBoostClassifier is handling natively those columns (you still need to pass the column names apparently).
Activity
glemaitre commentedon May 25, 2020
You need to encode the categorical features with a
ColumnTransformerand anOrdinalEncoderorOneHotEncoder. Scikit-learn does not handle natively the categorical data.CatBoostClassifieris handling natively those columns (you still need to pass the column names apparently).