Mathwords logoMathwords

Studentized Residual — Definition, Formula & Example

A studentized residual is a regression residual rescaled by its own estimated standard deviation. This puts every point's error on a common scale, so you can judge whether it is unusually large.

In a least-squares regression with nn observations and pp estimated parameters, the residual ei=yi−y^ie_i = y_i - \hat{y}_i has variance σ2(1−hii)\sigma^2(1 - h_{ii}), where hiih_{ii} is the leverage of observation ii. The internally studentized residual is ri=ei/(s1−hii)r_i = e_i / \left(s\sqrt{1 - h_{ii}}\right), where s=SSE/(n−p)s = \sqrt{\text{SSE}/(n-p)} is estimated from all nn observations, including observation ii. The externally studentized (deleted) residual instead uses s(i)s_{(i)}, computed with observation ii removed. Some textbooks and software, such as R's rstandard(), call rir_i the standardized residual, so check which definition your source uses.

Key Formula

ri=eis1−hii,hii=1n+(xi−xˉ)2∑j=1n(xj−xˉ)2 (simple linear regression)r_i = \frac{e_i}{s\sqrt{1 - h_{ii}}}, \qquad h_{ii} = \frac{1}{n} + \frac{(x_i - \bar{x})^2}{\sum_{j=1}^{n}(x_j - \bar{x})^2} \text{ (simple linear regression)}
Where:
  • rir_i = Studentized residual for observation i (unitless)
  • eie_i = Ordinary residual, observed minus predicted value
  • ss = Residual standard error, the square root of SSE/(n − p)
  • hiih_{ii} = Leverage of observation i, between 0 and 1; larger when xix_i is far from the mean
  • nn = Number of observations
  • pp = Number of estimated parameters (2 for a line: slope and intercept)
  • xˉ\bar{x} = Mean of the x-values

Worked Example

Problem: A simple linear regression predicts monthly electric bills (in dollars) from home size (in hundreds of square feet) for n=25n = 25 homes. The x-values have mean xˉ=18\bar{x} = 18 and ∑(xj−xˉ)2=200\sum (x_j - \bar{x})^2 = 200. The residual standard error is s=10s = 10. One 2,600-square-foot home (x=26x = 26) has a residual of $24. Find its studentized residual.
Step 1: Find the leverage of this home. It sits 8 units above the mean size, which raises its leverage.
hii=125+(26−18)2200=0.04+0.32=0.36h_{ii} = \frac{1}{25} + \frac{(26 - 18)^2}{200} = 0.04 + 0.32 = 0.36
Step 2: Find the estimated standard deviation of this particular residual.
s1−hii=100.64=10(0.8)=8s\sqrt{1 - h_{ii}} = 10\sqrt{0.64} = 10(0.8) = 8
Step 3: Divide the residual by that standard deviation.
ri=248=3r_i = \frac{24}{8} = 3
Answer: The studentized residual is 3. That is well beyond the common cutoff of 2 and reaches the stricter cutoff of 3, so you should investigate this home as a possible outlier.

Why It Matters

Regression output in a statistics or econometrics course lists studentized residuals because raw residuals cannot be compared fairly. Points far from the mean of x pull the fitted line toward themselves, which shrinks their residuals. Studentizing corrects for this, so analysts in fields like quality control and finance can flag observations with ∣ri∣>2|r_i| > 2 or ∣ri∣>3|r_i| > 3 before trusting a model.

Common Mistakes

Mistake: Dividing the residual by ss alone and ignoring leverage. In the example, this gives 24/10=2.424/10 = 2.4 instead of 3.
Correction: Each residual has its own standard deviation, s1−hiis\sqrt{1 - h_{ii}}. A high-leverage point has a smaller residual variance, so dividing only by ss understates how unusual its residual is.

Related Terms