Question: Suppose you have trained a decision tree model called ' dt ' in Python using sklearn.tree.DecisionTreeClassifier. Which of the following codes CAN be used to
Suppose you have trained a decision tree model called dt in Python using sklearn.tree.DecisionTreeClassifier. Which of the following codes CAN be used to generate the testing accuracy of the decision tree dt The testing dataset features is X test', and the true testing label is
Ytest'.
a from sklearn.metrics import accuracyscore
accuracyscoreytest, Xtest
b dtscoreXtest
c from sklearn.metrics import accuracyscore accuracyscorelytest, dtpredictXtest
d dtaccuracyXtest, ytest
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
