Encoders¶
The Encoders transform the categorical columns into numerical columns.
Note
The Encoders transform the data inplace. The output of an encoder is then a numerical dataframe or array. Before calling an encoder, all the transformations on categorical columns should be done and the datetime columns should be dropped.
BaseEncoder¶
Base encoder transformer class. |
Unsupervised Encoders¶
Encode the categorical columns as integer columns. |
|
Encode the categorical columns as integer columns based on the category count. |
|
Encode the categorical columns as one-hot numeric columns. |
|
Encode the categorical variables after running a Gators Binning transformer. |
Supervised Encoders¶
Encode all categorical variables using the weight of evidence technique. |
|
Encode the categorical variables using the target encoding technique. |
Note
WOEEncoder is only valid for binary classification problems, TargetEncoder works for binary and regression problems. In the case of a multiclass classification problem, it is recommended to use a one-versus-all approach in order to use the supervised encoders.