Random Forests are a type of Bagging technique.

Random Forests builds a number of trees on a bootstrapped sample. At each split in the tree, only a subset random sample of m predictors are considered.

By default for Classification we use and for Regression we use where is the number of predictors.

Method

  1. Create bootstrap samples.
  2. Fit a tree to each bootstrap sample while considering only a random subset of features for each split.
  3. Each decision tree is used to make a prediction.
  4. Aggregate all predictions.