Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Differences between sklearn's SimpleImputer and Imputer

In python's sklearn library there exist two classes, which are doing approximately the same things: sklearn.preprocessing.Imputer and sklearn.impute.SimpleImputer

The only difference that I found is a "constant" strategy type in SimpeImputer. Is there any other differences? When should be Imputer used instead of SimpleImputer?

like image 396
MefAldemisov Avatar asked Dec 24 '18 11:12

MefAldemisov


1 Answers

Imputer class is deprecated in 0.20 and will be removed in 0.22. Check the source code for details. Answer to your question is then easy: you should always use SimpleImputer.

like image 167
Lukasz Tracewski Avatar answered Nov 11 '22 20:11

Lukasz Tracewski