Leo Breiman introduced the random forest algorithm in a 2001 paper that unified two earlier ideas: bagging (bootstrap aggregating, Breiman 1996) and random subspace selection (Ho, 1998). The problem Breiman addressed was the high variance of individual decision trees. A single CART tree fit to macroeconomic data can produce wildly different splits depending on small perturbations of the training sample. Bagging reduces this variance by averaging predictions across many trees, each grown on a bootstrap resample of the data. Breiman's key addition was to decorrelate the trees further by restricting each split to a random subset of m features drawn from the full set of p predictors. This feature subsampling prevents a single dominant predictor from appearing at the root of every tree, forcing the ensemble to spread its explanatory weight across many variables. The result is a predictor whose variance decreases roughly as 1/B (where B is the number of trees) when trees are uncorrelated, compared to a much slower rate for plain bagging where tree correlation limits the gains.
The core mechanism operates at two levels. At the tree level, each base learner partitions the predictor space into axis-aligned rectangles and fits a constant (regression) or plurality vote (classification) within each rectangle. Trees are grown deep, typically to terminal nodes containing 5 or fewer observations, so each tree is a high-variance, low-bias estimator. At the ensemble level, the forest averages these overfit trees, exploiting the fact that their errors are approximately uncorrelated thanks to both bootstrap resampling and random feature selection. The prediction for a new observation is the average (regression) or majority vote (classification) across all B trees. Because each tree sees a different bootstrap sample and a different feature subset at each split, the ensemble captures a rich mosaic of interaction patterns that no single tree or linear model could represent.
Random forests have become standard tools in applied macroeconomics and central bank research. Goulet Coulombe et al. (2022) showed that random forests match or beat penalized linear models for US inflation and GDP growth forecasting when the predictor set exceeds 100 variables. The Bank of Canada uses random forests in its nowcasting toolkit alongside factor models and MIDAS regressions. The European Central Bank applies them for recession probability estimation, where nonlinear interactions between financial conditions and real activity matter. In finance, Gu, Kelly, and Xiu (2020) found random forests competitive with neural networks for cross-sectional stock return prediction. The Federal Reserve Bank of Philadelphia uses tree-based methods in its Survey of Professional Forecasters analysis to detect structural breaks in forecaster behavior.
Extensions of the base algorithm include extremely randomized trees (Geurts, Ernst, Wehenkel, 2006), which randomize split points as well as feature subsets; quantile regression forests (Meinshausen, 2006), which estimate conditional quantiles for density forecasting; and causal forests (Athey, Tibshirani, Wager, 2019), which estimate heterogeneous treatment effects in policy evaluation. Macroeconomic causal forests have been applied to estimate heterogeneous fiscal multipliers across country-time cells and to personalize monetary policy transmission estimates.