A regression tree chooses a threshold and constant predictions to minimize the squared-error criterion
where ranges over thresholds producing two nonempty groups. For a fixed split, the least-squares minimizers are the two sample means,
Thus the first split is the candidate threshold with the smallest sum of the two within-node residual sums of squares.
Start with the root region . For any current terminal region , coordinate , and threshold , form
discarding splits that leave an empty child. For each child use its training-response mean
Compare candidate splits by the resulting residual sum of squares
together with the unchanged residual sums in the other leaves. Choose the leaf, coordinate, and threshold minimizing the total. Replace that leaf by its two children and repeat until the stopping rule or the prescribed leaves is reached. The resulting terminal regions are , and
This is the standard regression tree construction.
Among all depth-one regression tree splits, the best split separates the second observation from the first and third by cutting advert1 between and . The test point with advert1 equal to zero reaches the leaf containing responses and , so the output is their arithmetic mean,
This decision stump makes a piecewise-constant prediction far outside the observed predictor range and cannot extrapolate the spending trend towards the origin. Its shallow structure and leaf averaging keep its variance of an estimator modest, while that extrapolation failure can produce substantial bias of an estimator.
Regression tree Created 2026-09-24 Updated 2026-09-24
A regression tree recursively partitions predictor space by axis-aligned splits. At each leaf, candidate coordinates and thresholds are compared by the residual sum of squares after replacing that leaf by its two children; the selected split minimizes the total criterion. The fitted value in each terminal region is the sample mean there.