scikit-learn-contrib / category_encoders

A library of sklearn compatible categorical variable encoders
http://contrib.scikit-learn.org/category_encoders/
BSD 3-Clause "New" or "Revised" License
2.4k stars 393 forks source link

Multiclass target encoder #363

Closed nercisla closed 2 years ago

nercisla commented 2 years ago

Implement fit and transform function of target encoding for multi-class target.

Proposed Changes

PaulWestenthanner commented 2 years ago

Is this the same thing that the PolynomialWrapper (not the obvious choice of name, sorry) does in a generic way for all encoders, so it is not needed specifically for target encoding? It pretty much looks like it, but I might miss something

nercisla commented 2 years ago

I think you are right, Paul, thanks! I never used this wrapper - possibly due to its name. I think I prefer the return of all encoded columns, but I can't see a justifiable use case for it. In light of this, a slightly unusable piece of code...

PaulWestenthanner commented 2 years ago

Alright. thanks for your work anyway and sorry again for the confusing naming