sklearn.base.TransformerMixin¶
-
class
sklearn.base.TransformerMixin[源代码]¶ Mixin class for all transformers in scikit-learn.
Methods
fit_transform(X[, y])Fit to data, then transform it. -
__init__()¶ Initialize self. See help(type(self)) for accurate signature.
-
fit_transform(X, y=None, **fit_params)[源代码]¶ 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: X : numpy array of shape [n_samples, n_features]
Training set.
y : numpy array of shape [n_samples]
Target values.
Returns: X_new : numpy array of shape [n_samples, n_features_new]
Transformed array.
-
