8000 DOC Ensures that FunctionTransformer passes numpydoc validation (#20939) · scikit-learn/scikit-learn@51a7bd5 · GitHub
[go: up one dir, main page]

Skip to content

Commit 51a7bd5

Browse files
baam25simoadrinjalali
authored andcommitted
DOC Ensures that FunctionTransformer passes numpydoc validation (#20939)
1 parent 77b4ee1 commit 51a7bd5

File tree

2 files changed

+14
-2
lines changed

2 files changed

+14
-2
lines changed

maint_tools/test_docstrings.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
DOCSTRING_IGNORE_LIST = [
1212
"Birch",
1313
"FeatureUnion",
14-
"FunctionTransformer",
1514
"GammaRegressor",
1615
"GaussianProcessRegressor",
1716
"GaussianRandomProjection",

sklearn/preprocessing/_function_transformer.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,15 @@ class FunctionTransformer(TransformerMixin, BaseEstimator):
7171
7272
.. versionadded:: 0.18
7373
74+
See Also
75+
--------
76+
MaxAbsScaler : Scale each feature by its maximum absolute value.
77+
StandardScaler : Standardize features by removing the mean and
78+
scaling to unit variance.
79+
LabelBinarizer : Binarize labels in a one-vs-all fashion.
80+
MultilabelBinarizer : Transform between iterable of iterables
81+
and a multilabel format.
82+
7483
Examples
7584
--------
7685
>>> import numpy as np
@@ -129,9 +138,13 @@ def fit(self, X, y=None):
129138
X : array-like, shape (n_samples, n_features)
130139
Input array.
131140
141+
y : Ignored
142+
Not used, present here for API consistency by convention.
143+
132144
Returns
133145
-------
134-
self
146+
self : object
147+
FunctionTransformer class instance.
135148
"""
136149
X = self._check_input(X)
137150
if self.check_inverse and not (self.func is None or self.inverse_func is None):

0 commit comments

Comments
 (0)
0