Skip to content

Commit b2af911

Browse files
jerokojnothman
authored andcommitted
DOC Remove unnecessary module prefix in example code. (scikit-learn#7884)
MultiLabelBinarizer is already imported, calling it with the ``preprocessing`` module prefix produces an error.
1 parent 915458b commit b2af911

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

doc/tutorial/basic/tutorial.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ is similarly possible for an instance to be assigned multiple labels::
390390

391391
>> from sklearn.preprocessing import MultiLabelBinarizer
392392
>> y = [[0, 1], [0, 2], [1, 3], [0, 2, 3], [2, 4]]
393-
>> y = preprocessing.MultiLabelBinarizer().fit_transform(y)
393+
>> y = MultiLabelBinarizer().fit_transform(y)
394394
>> classif.fit(X, y).predict(X)
395395
array([[1, 1, 0, 0, 0],
396396
[1, 0, 1, 0, 0],

0 commit comments

Comments
 (0)