Skip to content

Commit 6f6ec7f

Browse files
committed
Reference correct variable
1 parent 7af49df commit 6f6ec7f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sklearn/ensemble/bagging.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ def _fit(self, X, y, max_samples, max_depth=None, sample_weight=None):
298298

299299
# if max_samples is float:
300300
if not isinstance(max_samples, (numbers.Integral, np.integer)):
301-
max_samples = int(self.max_samples * X.shape[0])
301+
max_samples = int(max_samples * X.shape[0])
302302

303303
if not (0 < max_samples <= X.shape[0]):
304304
raise ValueError("max_samples must be in (0, n_samples]")

0 commit comments

Comments
 (0)