Why Bandwidth Selection Matters
A regression discontinuity estimate is local: it compares fitted outcome levels just below and just above an assignment threshold. The bandwidth \(h\) determines how local the comparison is. A smaller \(h\) uses observations closer to the cutoff, where smooth outcome trends may be easier to approximate, but leaves fewer observations and greater sampling variability. A larger \(h\) uses more data, but the fitted trends may poorly represent outcomes at the cutoff. Choosing a bandwidth is therefore part of choosing the estimator, not a harmless formatting decision.
This tutorial focuses on data-driven bandwidths for local polynomial regression discontinuity. The target is the discontinuity at a fixed cutoff \(c\), not a general prediction curve across the running-variable range. A selected bandwidth identifies which observations contribute to the local fit; it does not change the cutoff, the assignment rule, or the causal estimand.
Local Fits and the Bias–Variance Tradeoff
Let \(X_i\) be the running variable, \(Y_i\) the outcome, and \(c\) the assignment cutoff. For a sharp regression discontinuity, define \(D_i=1(X_i\ge c)\). The cutoff effect is the difference between the right- and left-hand limits of the conditional mean outcome at \(c\). A local polynomial estimator fits separate regressions on the two sides, using kernel weights that depend on \(h\), and takes the difference between the fitted values at the cutoff.
For a local linear fit, each side fits an intercept and slope using observations near \(c\). The intercepts estimate the two side-specific limits; their difference estimates the jump. A kernel determines how weight declines with distance, while the bandwidth determines the scale of that distance and the boundary of the window. The previous material on kernel weights explains the role of the weighting function; here the central decision is how wide the window should be.
Bandwidth selection is commonly based on an approximate mean squared error (MSE), the sum of squared bias and variance. Under smooth conditional mean functions on each side, positive running-variable density near the cutoff, independent observations, and finite outcome variance, the local linear discontinuity estimator typically has leading bias of order \(h^2\) and variance of order \(1/(nh)\). The constants depend on the side-specific curvature, the kernel, the design density, and outcome variability. In particular, a steep curvature near the cutoff can make a wide window costly in bias.
Here \(B\) and \(V\) summarize the leading bias and variance constants, and \(n\) is the sample size. The displayed expression is an approximation for choosing a bandwidth, not an exact finite-sample description. It makes the tradeoff visible: increasing \(h\) increases the leading squared-bias term, while decreasing \(h\) reduces the variance term by bringing more observations into the fit.
Why the MSE-Optimal Bandwidth Has This Form
The approximate optimal bandwidth minimizes the displayed MSE over positive \(h\). Differentiating with respect to \(h\), setting the derivative equal to zero, and solving gives:
This is a minimum: the derivative is negative for sufficiently small \(h\), positive for sufficiently large \(h\), and the second derivative \(12Bh^2+2V/(nh^3)\) is positive for every \(h>0\). The formula also shows the main directions of change. More noise, represented by larger \(V\), favors a wider window; stronger curvature, represented by larger \(B\), favors a narrower one. As \(n\) grows, the approximate optimal bandwidth shrinks at rate \(n^{-1/5}\), while the number of observations inside the window can still grow.
In practice, \(B\) and \(V\) are unknown. A plug-in selector estimates the quantities needed to approximate them from the observed data, then substitutes those estimates into an MSE criterion. Regression discontinuity selectors use information relevant to the cutoff jump and the local fits; a generic rule based only on how well a curve predicts outcomes across the full running-variable range may target a different objective. The chosen value is data-driven, but it is not assumption-free: the criterion and its inputs encode a model of local smoothness and variability.
Worked Example: Comparing Candidate Bandwidths
Suppose hypothetical data support the approximate local-linear MSE criterion \(\operatorname{MSE}(h)=0.08h^4+18/(400h)\). The running variable is measured in eligibility-score points. Compare bandwidths \(h=0.5\), \(h=1\), and \(h=1.5\) points.
For \(h=0.5\), \[ 0.08(0.5)^4+\frac{18}{400(0.5)} =0.005+0.09=0.095. \]
For \(h=1\), \[ 0.08(1)^4+\frac{18}{400(1)} =0.08+0.045=0.125. \]
For \(h=1.5\), \[ 0.08(1.5)^4+\frac{18}{400(1.5)} =0.405+0.03=0.435. \]
Among these three candidates, \(h=0.5\) has the smallest approximate MSE. The wider windows reduce the variance contribution, but in this example their bias contribution rises more sharply. This comparison checks the criterion's arithmetic; it does not establish that the assumed constants are accurately estimated or that the local polynomial model is adequate.
Worked Example: A Plug-In Bandwidth Calculation
Consider a hypothetical local linear analysis with \(n=1{,}000\) observations and estimated MSE constants \(B=0.05\) and \(V=25\). Assume these estimates are based on data with adequate observations on both sides of the cutoff and no indication that the local conditional means are too irregular for the smoothness approximation.
Substitute the values into the approximate optimal-bandwidth formula: \[ \widehat h_{\mathrm{opt}} =\left(\frac{25}{4(0.05)(1{,}000)}\right)^{1/5} =\left(\frac{25}{200}\right)^{1/5} =(0.125)^{1/5} \approx 0.660. \]
The selected window is approximately \(0.660\) running-variable units to either side when a common bandwidth is used. It is not \(0.660\) outcome units, and it does not mean that observations outside the window are invalid or that the cutoff effect applies only to people within that distance. It describes the locality of this particular fitted estimate.
What the Selected Window Means in the Data
A bandwidth is an analysis choice whose practical consequences depend on the running-variable distribution. If \(h\) is doubled, the number of observations used will not necessarily double: the density may vary, observations may be sparse near the cutoff, or the running variable may have discrete values. With a compact-support kernel, the window has a clear outer boundary, but observations near that boundary may have very little weight. Thus, the raw count inside the window and the amount of information in the weighted fit are not always the same.
The left and right sides may have different numbers of observations or different variability. Some procedures select separate bandwidths \(h_-\) and \(h_+\); others impose a common \(h\). Separate choices can reflect different curvature or noise on each side, but they also make the two local fits use different ranges. Whichever convention is used should be reported clearly. In every case, the target remains the difference in the fitted limits at \(c\), rather than a comparison of average outcomes across the entire selected window.
Worked Example: Translating a Bandwidth into a Window
Suppose a hypothetical eligibility score has cutoff \(c=50\), is measured in points, and observations are approximately evenly distributed at 100 per point on each side near the cutoff. A selected common bandwidth is \(h=0.7\) points, with a kernel that gives zero weight outside \([-1,1]\).
The window is \[ [c-h,c+h]=[50-0.7,\;50+0.7]=[49.3,\;50.7]. \]
Under the stated approximate density, the window contains about \(100(0.7)=70\) observations below the cutoff and about 70 above it, or about 140 in total. These are approximate counts, not guaranteed counts. A bandwidth of \(0.35\) points would give about 35 observations on each side under the same density, whereas a bandwidth of \(1.4\) points would give about 140 on each side. The wider window could improve precision, but whether it is worthwhile depends on how well the local linear trends represent the outcome near the cutoff.
Selection Approaches, Diagnostics, and Limitations
A plug-in selector is useful because it formalizes a criterion and adapts the bandwidth to estimated curvature and variability. A fixed, substantively chosen bandwidth can be transparent, but its justification should explain why that window is appropriate and why conclusions are not merely an artifact of the choice. Prediction cross-validation is another possible approach: it chooses a window or model to predict held-out outcomes. However, good prediction over a broad range is not the same target as low MSE for a jump at one cutoff. Cross-validation should not be treated as automatically equivalent to a cutoff-specific selector.
A data-driven choice is not proof that the selected window is reliable. Check the number and spread of observations on each side, the effective contribution of the kernel weights, and whether the fitted local relationship is being determined by only a few observations. Sparse support, a highly uneven running-variable distribution, or a few influential observations can make a nominally reasonable bandwidth unstable. Also examine whether estimated curvature or variability inputs are plausible; since the selector depends on them, noisy inputs can produce a noisy bandwidth.
A bandwidth should be interpreted alongside sensitivity to reasonable nearby choices. Large changes in the estimate across nearby windows can signal that the approximation is fragile, even if one selector returns a precise-looking number. Sensitivity is a diagnostic, not a license to choose whichever bandwidth gives a preferred result. Report the selection method, the bandwidth in running-variable units, whether it is common or side-specific, and the resulting window and sample support.
Bandwidth selection also has limits because the criterion balances errors under a particular approximation and target. It cannot repair a discontinuity in the running-variable distribution that undermines the design, make a poor local polynomial specification adequate, or create observations where there is little support. Nor does a bandwidth chosen for point-estimation MSE automatically settle how uncertainty should be quantified. The subsequent material on bias correction addresses a distinct issue; selecting \(h\) and accounting for estimation bias should not be conflated.
Specify the cutoff jump, polynomial order, kernel, and whether the bandwidth is common or side-specific.
Use a cutoff-relevant data-driven criterion and record the selected bandwidth in running-variable units.
Inspect observations, weights, and fit on both sides; investigate sparse or influential support.
Compare nearby reasonable bandwidths and report the method, window, and relevant limitations.
Check Your Understanding
Answer each question, then compare your reasoning with the solutions.
- If the approximate local-linear MSE is \(0.04h^4+12/(600h)\), calculate the MSE at \(h=0.5\) and \(h=1\). Which is smaller?
- For that criterion, calculate the minimizing bandwidth using the derivative condition.
- A cutoff is \(c=20\) and a compact-support kernel is used with \(h=0.8\). What running-variable interval receives nonzero weight?
- Why might a prediction cross-validation bandwidth differ from a cutoff-specific MSE bandwidth?
- What does a large change in the estimated discontinuity across nearby bandwidths suggest, and what does it not prove?
Solutions. (1) At \(h=0.5\), \(0.04(0.5)^4+12/[600(0.5)]=0.0025+0.04=0.0425\). At \(h=1\), \(0.04+12/600=0.0600\). The smaller approximate MSE is at \(h=0.5\). (2) Here \(B=0.04\), \(V=12\), and \(n=600\), so \(h_{\mathrm{opt}}=[12/(4(0.04)(600))]^{1/5}=(0.125)^{1/5}\approx0.660\). (3) The interval is \([20-0.8,20+0.8]=[19.2,20.8]\). (4) Prediction cross-validation targets predictive performance for its validation setup, whereas a cutoff-specific selector targets error in estimating the jump at the threshold. (5) Sensitivity suggests the estimate may depend materially on the local approximation or available support. It does not, by itself, prove that one particular bandwidth is correct or that the design is invalid.