The Wild Bootstrap
A bootstrap variant built for regression with heteroskedastic errors — instead of resampling rows, it keeps every observation's x fixed and randomly flips the sign (or scale) of each residual, preserving each point's own error variance.
Prerequisites: Bootstrap and Resampling, The Classical Linear Regression Assumptions
You've run a regression of trade cost against order size, and the residuals clearly fan out — small orders have tight, predictable costs, large orders have wild, unpredictable costs. This is heteroskedasticity, and it breaks the usual bootstrap trick of resampling whole rows of data: shuffling rows around mixes up which residual variance belongs with which order size, destroying exactly the pattern you're trying to preserve. The wild bootstrap fixes this by never actually resampling observations at all — it keeps every and every residual's magnitude exactly where it was, and only randomizes the residual's sign.
An analogy: shaking a tree, not swapping branches
Imagine a tree where each branch has a different amount of natural sway — thick low branches barely move, thin high branches whip around wildly. To simulate "what if the wind blew differently today," you wouldn't swap a thick branch's motion onto a thin branch's position — that would misrepresent how much each branch can actually move. Instead you'd let each branch keep its own natural range of motion and just randomize which direction, left or right, it happens to sway on a given gust. The wild bootstrap does exactly this to regression residuals: each residual keeps its own magnitude (its own "amount of sway," tied to its original observation's variance) and only its sign gets randomly flipped.
The idea, one symbol at a time
Given a fitted regression with residuals , the wild bootstrap generates a pseudo-dataset by
where is drawn independently for each observation from a simple two-point distribution — most commonly the Rademacher distribution, or each with probability . In plain English: keep the fitted line and every exactly as they were, and for each observation randomly either keep its residual as-is or flip its sign — never swap a residual from one observation onto another observation's . Refitting the regression on many such pseudo-datasets and collecting the resulting coefficient estimates builds a distribution that reflects each observation's own error variance, because always has exactly the magnitude of , whatever the sign — unlike resampling rows, which could easily place a small-order residual next to a large-order or vice versa.
Worked example 1: three points by hand
Suppose a tiny regression with 3 residuals: (small order, small residual), (large order, large residual), (large order, large residual). One wild bootstrap draw might sample , giving pseudo-residuals — note . A different draw might give , giving . In both cases, observation 1's contribution stays small and observations 2 and 3's stay large — a naive row-resampling bootstrap could instead draw observation 1 three times, producing three small residuals and completely losing the fact that large orders carry more uncertainty.
Worked example 2: comparing standard errors
Suppose the standard OLS formula (assuming constant residual variance) gives a standard error of for the order-size coefficient, but the data is known to be heteroskedastic. Running wild bootstrap replications, refitting the regression each time and recording , might produce a spread with standard deviation — noticeably wider than the naive OLS standard error, correctly reflecting the extra uncertainty contributed by the large, volatile residuals at high order sizes that the constant-variance formula ignored. Using the naive instead of the wild-bootstrap-based would make the coefficient's confidence interval look artificially tight, potentially leading you to treat a noisy estimate as more precise than it really is.
What this means in practice
The wild bootstrap is the standard fix whenever you need bootstrap standard errors or confidence intervals for a regression with residuals that clearly change in variance across the range of the data — common in market-impact regressions, cost models, and anywhere order size or trade size varies widely. It's also the preferred approach in small-sample or few-cluster settings (clustered wild bootstrap) where standard cluster-robust formulas are known to be unreliable.
The wild bootstrap resamples regression residuals in place by randomly flipping their sign (keeping every observation's x and its own residual magnitude fixed), rather than resampling whole rows — this preserves heteroskedastic error structure that a naive row-resampling bootstrap would scramble.
The wild bootstrap fixes heteroskedasticity but does nothing about autocorrelation between residuals — if your regression residuals are also serially correlated (common in time series regressions with overlapping windows or persistent trading signals), sign-flipping each residual independently still assumes they're independent across observations, which a purely heteroskedasticity-focused fix does not address. A block or cluster wild bootstrap is needed when both problems are present at once.
Related concepts
Practice in interviews
Further reading
- Wu, 'Jackknife, Bootstrap and Other Resampling Methods in Regression Analysis', Annals of Statistics
- MacKinnon, 'Wild Cluster Bootstrap Confidence Intervals'