Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 6222054

Browse filesBrowse files
authored
DOC: Fixes Docs for estimator types do not list all possible estimator types (#29956)
1 parent c6777b6 commit 6222054
Copy full SHA for 6222054

File tree

Expand file treeCollapse file tree

1 file changed

+10
-3
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+10
-3
lines changed

‎doc/developers/develop.rst

Copy file name to clipboardExpand all lines: doc/developers/develop.rst
+10-3Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -475,9 +475,16 @@ on a classifier, but not otherwise. Similarly, scorers for average precision
475475
that take a continuous prediction need to call ``decision_function`` for classifiers,
476476
but ``predict`` for regressors. This distinction between classifiers and regressors
477477
is implemented using the ``_estimator_type`` attribute, which takes a string value.
478-
It should be ``"classifier"`` for classifiers and ``"regressor"`` for
479-
regressors and ``"clusterer"`` for clustering methods, to work as expected.
480-
Inheriting from ``ClassifierMixin``, ``RegressorMixin`` or ``ClusterMixin``
478+
This attribute should have the following values to work as expected:
479+
480+
- ``"classifier"`` for classifiers
481+
- ``"regressor"`` for regressors
482+
- ``"clusterer"`` for clustering methods
483+
- ``"outlier_detector"`` for outlier detectors
484+
- ``"DensityEstimator"`` for density estimators
485+
486+
Inheriting from :class:`~base.ClassifierMixin`, :class:`~base.RegressorMixin`, :class:`~base.ClusterMixin`,
487+
:class:`~base.OutlierMixin` or :class:`~base.DensityMixin`,
481488
will set the attribute automatically. When a meta-estimator needs to distinguish
482489
among estimator types, instead of checking ``_estimator_type`` directly, helpers
483490
like :func:`base.is_classifier` should be used.

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.