@@ -176,12 +176,12 @@ class LabelBinarizer(TransformerMixin, BaseEstimator):
176
176
At learning time, this simply consists in learning one regressor
177
177
or binary classifier per class. In doing so, one needs to convert
178
178
multi-class labels to binary labels (belong or does not belong
179
- to the class). LabelBinarizer makes this process easy with the
179
+ to the class). ` LabelBinarizer` makes this process easy with the
180
180
transform method.
181
181
182
182
At prediction time, one assigns the class for which the corresponding
183
- model gave the greatest confidence. LabelBinarizer makes this easy
184
- with the inverse_transform method.
183
+ model gave the greatest confidence. ` LabelBinarizer` makes this easy
184
+ with the :meth:` inverse_transform` method.
185
185
186
186
Read more in the :ref:`User Guide <preprocessing_targets>`.
187
187
@@ -204,13 +204,13 @@ class LabelBinarizer(TransformerMixin, BaseEstimator):
204
204
205
205
y_type_ : str
206
206
Represents the type of the target data as evaluated by
207
- utils.multiclass.type_of_target. Possible type are 'continuous',
208
- 'continuous-multioutput', 'binary', 'multiclass',
207
+ :func:`~sklearn. utils.multiclass.type_of_target` . Possible type are
208
+ 'continuous', 'continuous -multioutput', 'binary', 'multiclass',
209
209
'multiclass-multioutput', 'multilabel-indicator', and 'unknown'.
210
210
211
211
sparse_input_ : bool
212
- True if the input data to transform is given as a sparse matrix, False
213
- otherwise.
212
+ ` True` if the input data to transform is given as a sparse matrix,
213
+ `False` otherwise.
214
214
215
215
See Also
216
216
--------
@@ -374,9 +374,9 @@ def inverse_transform(self, Y, threshold=None):
374
374
threshold : float, default=None
375
375
Threshold used in the binary and multi-label cases.
376
376
377
- Use 0 when ``Y`` contains the output of decision_function
377
+ Use 0 when ``Y`` contains the output of :term:` decision_function`
378
378
(classifier).
379
- Use 0.5 when ``Y`` contains the output of predict_proba.
379
+ Use 0.5 when ``Y`` contains the output of :term:` predict_proba` .
380
380
381
381
If None, the threshold is assumed to be half way between
382
382
neg_label and pos_label.
@@ -389,10 +389,10 @@ def inverse_transform(self, Y, threshold=None):
389
389
Notes
390
390
-----
391
391
In the case when the binary labels are fractional
392
- (probabilistic), inverse_transform chooses the class with the
392
+ (probabilistic), :meth:` inverse_transform` chooses the class with the
393
393
greatest value. Typically, this allows to use the output of a
394
- linear model's decision_function method directly as the input
395
- of inverse_transform.
394
+ linear model's :term:` decision_function` method directly as the input
395
+ of :meth:` inverse_transform` .
396
396
"""
397
397
check_is_fitted (self )
398
398
0 commit comments