Exam PA · Tree-Based Models · Free Lesson

Apply bagging and random forests as appropriate.

Free SOA Exam PA (Predictive Analytics) lesson in Tree-Based Models. 11 min read, ~1,654 words.

A single pruned tree is easy to read but jumpy: shift a few training rows and the top split flips. Bagging and random forests trade that instability for accuracy by averaging many trees.

Why average trees at all. A deep tree has low bias but high variance. Averaging many independent predictions cuts variance without raising bias. That is the whole engine behind both methods.

Bagging. Draw B bootstrap samples (sample n rows with replacement). Fit one unpruned tree per sample. To predict, average the B regression outputs or take the majority class.

Var⁡=ρσ2+1−ρBσ2\operatorname{Var} = \rho\sigma^{2} + \frac{1-\rho}{B}\sigma^{2}

Push BB high and the second term vanishes, but the first term ρσ2\rho\sigma^2 stays. That floor is bagging's weakness: bootstrap trees are highly correlated because one or two strong predictors dominate the top split in every tree.

KEY: Random forests attack the correlation term ρ\rho, not the count BB. At each split they consider a random subset of mtry predictors, so strong predictors cannot own every tree. Lower ρ\rho, lower variance.

Read the full lesson, free →
Worked examples and practice. Free with a free account, no card.

Common mistakes

Bottom line

Exam shortcut

For any bagging arithmetic task, average every tree first, then take the absolute value before comparing errors; the two most common lost points are using one tree and dropping the absolute value. When recommending mtry (or any random forest parameter), read the tuning plot, name the value at the error minimum, and add one sentence on why it beats its neighbors.

The full lesson (about 1,654 words, 11 min read) adds 2 worked examples, all 6 common mistakes, a self-check, free in the app.

Learning objectives

Browse all free Exam PA lessons or jump into free Exam PA practice questions.