@@ -30,16 +30,15 @@ class TransformedTargetRegressor2(BaseEstimator, RegressorMixin):
30
30
Useful for applying a non-linear transformation in regression
31
31
problems.
32
32
33
- :param regressor: object, `default=LinearRegression()`
33
+ Parameters
34
+ ----------
35
+
36
+ regressor : object, `default=LinearRegression()`
34
37
Regressor object such as derived from ``RegressorMixin``. This
35
38
regressor will automatically be cloned each time prior to fitting.
36
- :param transformer: str or object of type :class:`BaseReciprocalTransformer
37
- <mlinsights.mlmodel.sklearn_transform_inv.BaseReciprocalTransformer>`
38
-
39
- Attributes:
40
39
41
- * regressor_: object, fitted regressor.
42
- * transformer_: object, Transformer used in ``fit`` and ``predict``.
40
+ transformer : str or object of type :class:`BaseReciprocalTransformer
41
+ <mlinsights.mlmodel.sklearn_transform_inv.BaseReciprocalTransformer>`
43
42
44
43
Examples
45
44
--------
@@ -59,7 +58,11 @@ class TransformedTargetRegressor2(BaseEstimator, RegressorMixin):
59
58
print(tt.score(X, y))
60
59
print(tt.regressor_.coef_)
61
60
62
- See notebook :ref:`l-sklearn-transformed-target` for a more complete example.
61
+ See example :ref:`l-sklearn-transformed-target` for a more complete example.
62
+
63
+ The class holds two attributes `regressor_`, the fitted regressor,
64
+ `transformer_` transformer used in ``fit``, ``predict``,
65
+ ``decision_function``, ``predict_proba``.
63
66
"""
64
67
65
68
def __init__ (self , regressor = None , transformer = None ):
@@ -135,19 +138,17 @@ class TransformedTargetClassifier2(BaseEstimator, ClassifierMixin):
135
138
Useful for applying permutation transformation in classification
136
139
problems.
137
140
138
- :param classifier: object, default=LogisticRegression()
141
+ Parameters
142
+ ----------
143
+
144
+ classifier : object, default=LogisticRegression()
139
145
Classifier object such as derived from ``ClassifierMixin``. This
140
146
classifier will automatically be cloned each time prior to fitting.
141
- :param transformer: str or object of type :class:`BaseReciprocalTransformer
147
+
148
+ transformer : str or object of type :class:`BaseReciprocalTransformer
142
149
<mlinsights.mlmodel.sklearn_transform_inv.BaseReciprocalTransformer>`
143
150
Transforms the features.
144
151
145
- Attributes:
146
-
147
- * classifier_ : object, Fitted classifier.
148
- * transformer_ : object Transformer used in ``fit``, ``predict``,
149
- ``decision_function``, ``predict_proba``.
150
-
151
152
Examples:
152
153
153
154
.. runpython::
@@ -165,7 +166,11 @@ class TransformedTargetClassifier2(BaseEstimator, ClassifierMixin):
165
166
print(tt.score(X, y))
166
167
print(tt.classifier_.coef_)
167
168
168
- See notebook :ref:`l-sklearn-transformed-target` for a more complete example.
169
+ See example :ref:`l-sklearn-transformed-target` for a more complete example.
170
+
171
+ The class holds two attributes `classifier_`, the fitted classifier,
172
+ `transformer_` transformer used in ``fit``, ``predict``,
173
+ ``decision_function``, ``predict_proba``.
169
174
"""
170
175
171
176
def __init__ (self , classifier = None , transformer = None ):
0 commit comments