Random Forest Classifier
If you think about the name Random forest classifier, it makes sense to conclude the following:
- A forest consists of multiple trees.
- These trees can be used for classification.
- Since the only tree we have used so far for classification is a decision tree, it makes sense that the random forest is a forest of decision trees.
- The random nature of the trees means that our decision trees are constructed in a randomized manner.
- As a consequence, we will base our decision tree construction on information gain or Gini Impurity.
Once you understand these basic concepts, you essentially know what a Random forest classifier is all about. The more trees you have in the forest, the more accurate prediction is going to be. When performing prediction, each tree performs classification. We collect the results, and the class that gets the most votes wins.
Random forests can be used for regression as well as for classification. When using random...