Types of Ensemble Learning (original) (raw)

Last Updated : 23 Dec, 2025

Ensemble Learning in machine learning that integrates multiple models called as weak learners to create a single effective model for prediction. This technique is used to enhance accuracy, minimizing variance and removing overfitting. Here we will learn different ensemble techniques and their algorithms.

Bagging (Bootstrap Aggregating)

Bagging is a technique that involves creating multiple versions of a model and combining their outputs to improve overall performance.

In bagging several base models are trained on different subsets of the training data, then aggregate their predictions to make the final decision. The subsets of the data are created using **bootstrapping, a statistical technique where samples are drawn with replacement, meaning some data points can appear more than once in a subset.

The final prediction from the ensemble is typically made by either:

This approach helps to reduce variance, especially with models that are prone to overfitting, such as decision trees.

**Common Algorithms Using Bagging

**1. Random Forest

**2. Bagged Decision Trees

**Boosting

**Boosting is an ensemble technique where multiple models are trained sequentially, with each new model attempting to correct the errors made by the previous ones.

Boosting focuses on adjusting the weights of incorrectly classified data points, so the next model pays more attention to those difficult cases. By combining the outputs of these models, boosting typically improves the accuracy of the final prediction.

In boosting, each new model is added to the ensemble in a way that emphasizes the mistakes made by previous models. The final prediction is usually made by combining the weighted predictions of all the models in the ensemble.

The final prediction from the ensemble is typically made by:

This approach helps to reduce bias, especially when using weak learners, by focusing on the misclassified points.

**Common Algorithms Using Boosting

**1. AdaBoost (Adaptive Boosting)

**2. Gradient Boosting

**3. XGBoost (Extreme Gradient Boosting)

**Stacking

Stacking (Stacked Generalization) combines multiple models (base learners) of different types, where each model makes independent predictions and a meta-model is trained to combine these predictions. Instead of simply averaging or voting, as in bagging and boosting, stacking trains a higher-level model (meta-model) to learn how to best combine the predictions of the base models.

In stacking, the base models are trained on the original data and their predictions are then used as features for the meta-model, which learns how to combine them effectively. The final prediction is made by the meta-model based on the combined outputs of all the base models.

The final prediction from the ensemble is typically made by:

**Common Algorithms Using Stacking

**1. Generalized Stacking

**2. Stacking with Cross-Validation

**3. Multi-Layer Stacking