Random Forests Lab
Let's code the random forest in R language.
Goal
In this lab, we’ll again try to predict players’ skill level, that is, the SkillLevel
column, which takes integer values between 0
and 3
, with 0
being novice
and 3
being expert
. We’ll use random forests in this lab. There are many different implementations of random forest (RF) that are wrapped and provided in caret
(check out this link for available models incaret
). We are going to use the implementation by ranger
, since it is reportedly faster than others, and it provides more freedom to tune the parameters.
Brief refresher
Random forest (RF) is an ensemble method—that is, a collection of models that builds upon decision trees—thus the forest in its name. As such, it’s able to capture nonlinearity in the data, is more robust to noise, and is less prone to overfitting.
Preparation
Get hands-on with 1400+ tech skills courses.