Exercise 4: Using Gain Ratio as a Splitting Criteria
The Decision Tree: Interactively build it
- Click on the root node below and start building the tree.
- Non leaf nodes can be "pruned" once they have been chosen (by clicking on the node and selecting "prune node completely")
- The ratios on the branches indicate how well the chosen attribute at a node splits the remaining data based on the target attribute (‘outcome’). s
- Click on any nodes to hilight the rows in the data table that the rule down to that node covers.
- At each node, the entropy of the data at that point in the tree will be given.
- Information gain (entropy reduction) is specified for each attribute.
Reducing entropy to zero is a way of building a decision tree here.
When no more nodes can be expanded, the tree has classified all the training data.
- Notice that the date attribute is calculated as having a high information gain.
- The gain ratio of an attribute is now also shown at each node construction phase, after the Information Gain value.
- See how the two differ and explore the types of trees that each produces.
- If we are to assume that the Date has no bearing on the Outcome, then which method produces the smaller trees?