Session Ready
Exercise

Bagging: the scikit-learn way

Let's now apply scikit-learn's BaggingClassifier to the Pokémon dataset.

You obtained an F1 score of around 0.56 with your custom bagging ensemble.

Will BaggingClassifier() beat it? Time to find out!

Instructions
100 XP
  • Instantiate the base model, clf_dt: a "restricted" decision tree with a max depth of 4.
  • Build a bagging classifier using 21 estimators, with the decision tree as base estimator.
  • Predict the labels of the test set.