[MXML-2-10] Decision Trees [10/11] - CART, Implement Pruning using CCP, Multiclass Classification

preview_player
Показать описание
* This video was produced in Korean and translated into English. And the voice is generated by AI TTS. The English translation may contain grammatical errors.

In this video, we will implement Cost Complexity Pruning (CCP) using Scikit-learn's DecisionTreeClassifier. We'll implement CCP by referring to the document below.

We use the training data to build a deep tree and create the alpha list. Then, we perform cross-validation to find the optimal alpha from the alpha list. We then create a final model with optimal alpha and use test data to evaluate the model's final performance.

And we will look at multiclass classification, which has more than 2 classes. So far we have looked at binary classification, which consists of two classes: (0, 1). Even if there are multiple classes, entropy and Gini index can be calculated in the same way as binary classification.

In binary classification, the maximum value of entropy is 1.0, and the maximum value of the Gini index is 0.5, but in multiclass case, the entropy is greater than 1.0, and the Gini index is greater than 0.5.

#DecisionTree #CART #Pruning #CostComplexityPruning #PostPruning #CCP #Multiclass #MulticlassClassification #MulticlassEntropy #MulticlassGini
Рекомендации по теме