📅  最后修改于: 2022-03-11 14:45:33.324000             🧑  作者: Mango
from sklearn.datasets import load_iris
from sklearn import tree
iris = load_iris()
X, y = iris.data, iris.target
clf = tree.DecisionTreeClassifier()
clf = clf.fit(X, y)