Answers for "imputer python example"

2

SimpleImputer

imr = Imputer(missing_values='NaN', strategy='median', axis=0)
imr = imr.fit(data[['age']])
data['age'] = imr.transform(data[['age']]).ravel()
Posted by: Guest on June-01-2020
1

sciket learn imputer code

from sklearn.preprocessing import Imputerimputer = Imputer(missing_values = 'NaN', strategy = 'mean', axis = 0)imputer = imputer.fit(X[:, 1:3])X[:, 1:3] = imputer.transform(X[:, 1:3])
Posted by: Guest on May-27-2020

Code answers related to "imputer python example"

Browse Popular Code Answers by Language