diff --git a/maint_tools/test_docstrings.py b/maint_tools/test_docstrings.py index 62dc51a4c0da1..78c09fe4c1218 100644 --- a/maint_tools/test_docstrings.py +++ b/maint_tools/test_docstrings.py @@ -127,7 +127,6 @@ "RadiusNeighborsClassifier", "RadiusNeighborsRegressor", "RadiusNeighborsTransformer", - "RandomForestClassifier", "RandomTreesEmbedding", "RandomizedSearchCV", "RegressorChain", diff --git a/sklearn/ensemble/_forest.py b/sklearn/ensemble/_forest.py index fa3567370cd18..d13cc2391b8e0 100644 --- a/sklearn/ensemble/_forest.py +++ b/sklearn/ensemble/_forest.py @@ -613,13 +613,7 @@ def feature_importances_(self): ) @property def n_features_(self): - """Number of features when fitting the estimator. - - Returns - ------- - n_features_in_ : int - The number of features when fitting the estimator. - """ + """Number of features when fitting the estimator.""" return self.n_features_in_ @@ -1293,7 +1287,9 @@ class labels (multi-output problem). See Also -------- - DecisionTreeClassifier, ExtraTreesClassifier + sklearn.tree.DecisionTreeClassifier : A decision tree classifier. + sklearn.ensemble.ExtraTreesClassifier : Ensemble of extremely randomized + tree classifiers. Notes -----