Skip to content

Commit ec2a89a

Browse files
committed
Merge pull request scikit-learn#4640 from dougalsutherland/patch-1
[MRG+1] ForestClassifier.predict docstring correction
2 parents 211c916 + 027eb6d commit ec2a89a

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

sklearn/ensemble/forest.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -444,8 +444,10 @@ def _validate_y_class_weight(self, y):
444444
def predict(self, X):
445445
"""Predict class for X.
446446
447-
The predicted class of an input sample is computed as the majority
448-
prediction of the trees in the forest.
447+
The predicted class of an input sample is a vote by the trees in
448+
the forest, weighted by their probability estimates. That is,
449+
the predicted class is the one with highest mean probability
450+
estimate across the trees.
449451
450452
Parameters
451453
----------

0 commit comments

Comments
 (0)