Question: For Decision Tree: ( 3 points ) Based on the output from tree _ clf . predict _ proba and tree _ clf . predict,
For Decision Tree:
points Based on the output from treeclfpredictproba and treeclfpredict, explain the predicting results. How do you decide which category an instance belongs to
points Were the predictions for these instances correct? Why?
points Modify the DecisionTreeClassifier model with the following hyperparameter settings:
maximum depth:
measure with "entropy" instead of "Gini impurity"
For Random Forest:
points Split the original dataset into training set and test set
points Train the random forest with the training set.
points Apply the trained classifier to the test data.
points Predict the category of the following instance print out the category name:
sepal length sepal width petal length petal width
points Print the score and the confusion matrix of the classifier.
Note: You can directly update the code for coding questions. You need to answer the remaining questions in a Markdown field.
points Create a new Markdown field at the end of this file and put your answers in this field. Submit this file to the Blackboard.
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
