Question: This activity aims to use the Decision Tree algorithm for pima - indians - diabetes dataset. Instructions: Create a Decision Tree, train it to fit
This activity aims to use the Decision Tree algorithm for pimaindiansdiabetes dataset.
Instructions:
Create a Decision Tree, train it to fit of the data, and test your model with the remaining
The following tasks can be performed:
Import necessary tools
Data exploration and preparation
Creating and training the model
The hyperparameter splitting criteria for categorical outputs are: gini or entropy Entropy corresponds to the ID algorithm. The gini is the one used in the cart algorithm. Nevertheless, it is interesting to experiment with both splitting criteria.
The hyperparameter maxdepth can be varied to handle the overfitting. It fixes the depth of the tree.
The hyperparameter minsamplessplit also can be varied; it corresponds to the minimum number of samples under which the node can be spitted.
Tree visualization you can visualize the tree for different hyperparameters
Testing and measuring performance
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
