Warning
DEPRECATED
class sklearn.preprocessing.Imputer(*args, **kwargs)
[source]
Imputation transformer for completing missing values.
Read more in the User Guide.
Parameters: |
|
---|---|
Attributes: |
|
axis=0
, columns which only contained missing values at fit
are discarded upon transform
.axis=1
, an exception is raised if there are rows for which it is not possible to fill in the missing values (e.g., because they only contain missing values).
fit (X[, y]) | Fit the imputer on X. |
fit_transform (X[, y]) | Fit to data, then transform it. |
get_params ([deep]) | Get parameters for this estimator. |
set_params (**params) | Set the parameters of this estimator. |
transform (X) | Impute all missing values in X. |
__init__(*args, **kwargs)
[source]
DEPRECATED: Imputer was deprecated in version 0.20 and will be removed in 0.22. Import impute.SimpleImputer from sklearn instead.
fit(X, y=None)
[source]
Fit the imputer on X.
Parameters: |
|
---|---|
Returns: |
|
fit_transform(X, y=None, **fit_params)
[source]
Fit to data, then transform it.
Fits transformer to X and y with optional parameters fit_params and returns a transformed version of X.
Parameters: |
|
---|---|
Returns: |
|
get_params(deep=True)
[source]
Get parameters for this estimator.
Parameters: |
|
---|---|
Returns: |
|
set_params(**params)
[source]
Set the parameters of this estimator.
The method works on simple estimators as well as on nested objects (such as pipelines). The latter have parameters of the form <component>__<parameter>
so that it’s possible to update each component of a nested object.
Returns: |
|
---|
transform(X)
[source]
Impute all missing values in X.
Parameters: |
|
---|
© 2007–2018 The scikit-learn developers
Licensed under the 3-clause BSD License.
http://scikit-learn.org/stable/modules/generated/sklearn.preprocessing.Imputer.html