Machine Learning, Decision Tree, Python, Tutorial, Learning.
repeat this splitting procedure at each child node until the leaves are pure — i.e. samples at each node all belong to the same class. In practice, this can result in a very deep tree with many nodes, which can easily lead to overfitting. Thus, we typically want to prune the tree by setting a limit