Decision trees

We now move on to one of the easily interpretable and most popular classifiers there are out there: the decision tree. Decision trees, which look like an upside down tree with the trunk on top and the leaves on the bottom, play an important role in situations where classification decisions have to be transparent and easily understood and explained. They also handle both continuous and categorical predictors, outliers, and irrelevant predictors rather gracefully. Finally, the general idea behind the algorithms that create decision trees are quite intuitive, though the details can sometimes get hairy.

Figure 10.7 depicts a simple decision tree designed to classify motor vehicles into either motorcycles, golf carts, or sedans: ...

Get Data Analysis with R - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.