feature_engine icon indicating copy to clipboard operation
feature_engine copied to clipboard

`OrdinalEncoder` could output -1 for unseen categories

Open solegalli opened this issue 2 years ago • 1 comments

The OrdinalEncoder has an errors argument which can either raise an error or output NaNs when encountering new categories. For this particular class, it'd make sense to output -1 when a new category is encoded instead of generating NaNs.

solegalli avatar Apr 25 '22 17:04 solegalli

We did this for the CountEncoder already. I think the best would be to have a look at how we implemented there?

solegalli avatar Aug 13 '22 12:08 solegalli