At the beginning of this chapter, we discussed why we use ensemble learning and how it can improve prediction performance compared to using just a single classifier. We will now validate whether the ensemble model performs better than a single decision tree by comparing the performance of each method. In order to compare the different classifiers, we can perform a 10-fold cross-validation on each classification method to estimate test errors using erroreset from the ipred package.
Estimating the prediction errors of different classifiers
Getting ready
In this recipe, we will continue to use the telecom churn dataset as the input data source to estimate the prediction errors of the different classifiers.