10 Multicollinearity & Polynomial Regression & Interaction Models

Multicollinearity

Venn Diagram

227

  • Blue: variation in yy uniquely attributable to XX.
  • Green: variation in yy uniquely attributable to WW.
  • Red: don't which one to attribute to, and can be negative (suppressor variables)
  • Yellow: variation in yy that cannot be explained, estimate for σ2\sigma^{2}.

Zero Collinearity

Here we discuss an extreme case where the explanatory variables have zero collinearity, i.e., they are uncorrelated. For simplicity, we assume the pairwise sample correlation to be zero:

X∗TX∗=IX^{*T}X^{*}=I

where X∗X^{*} is XX without all-one column after correlation transformation.

We call this XX as Orthogonal Design.

So b∗=X∗TY=[r1…rp−1]Tb^{*}=X^{*T}Y=\begin{bmatrix}r_{1} & \dots & r_{p-1}\end{bmatrix}^T, where rkr_{k} is the sample correlation between XkX_{k} and YY. Therefore

b=[sYs1r1…sYsp−1rp−1]Tb=\begin{bmatrix} \dfrac{s_{Y}}{s_{1}}r_{1} & \dots & \dfrac{s_{Y}}{s_{p-1}}r_{p-1} \end{bmatrix}^T

thus

V[bk]=σ2∑(Xik−Xˉk)2\mathbb{V}[b_{k}]=\frac{\sigma^{2}}{\sum (X_{ik}-\bar{X}_{k})^{2}}

(Expand sYskrk\frac{s_{Y}}{s_{k}}r_k and take its variance to get it.)

We can observe some properties of this design:

  • The coefficient estimation bkb_{k} does not depend on the other explanatory variables
  • The contribution of explanatory variable XkX_{k} to SSTSST is clear cut, and type I and III (or II) SS of XkX_{k} will be the same.
  • If the linear model is true, orthogonal design is optimal, i.e., variances are the smallest possible (high power)
  • p-values for testing βk\beta_{k} will change if we add or ignore other variables. Because MSEMSE, which depends on included variables, will change.
    146

Perfect Collinearity

Here we talk about another extreme case where XX doesn't have full column rank. In this case (XTX)−1(X^TX)^{-1} doesn't exist, so bb can not be estimated.

This XX is called Degenerate Design.

The normal equation has infinite solutions. Geometrically speaking:

For each perfect linear relation, the involved explanatory variables are confounded, and at least one is redundant.

It is possible to mathematically remove the redundancy by deleting one of the explanatory variables, so that the reduced model can be fitted, and coefficients of the remaining variables can be estimated. But which one to remove cannot be decided. The model is not identifiable.

General Case

When design matrix XX is not very good nor very bad, i.e., XTXX^TX is invertible but not orthogonal designed.

We have

bk∼N(βk,σ2[(XTX)−1]k,k)b_{k}\sim N(\beta_{k},\sigma^{2}[(X^TX)^{-1}]_{k,k})

and

[(XTX)−1]k,k=1xkT(I−P−k)xk[(X^TX)^{-1}]_{k,k} =\frac{1}{x_k^T(I-P_{-k})x_k}

where P−kP_{-k} is the projection matrix of X−kX_{-k} (XX excluded the kk-th column). We can obtain this by Schur complement.

So if XTXX^TX is close to singular, the variance of bkb_{k} would inflate.

When the amount of correlation becomes large,

  • Ambiguity between the involved variables increases, making it difficult to interpret the regression coefficients
  • Type I SS and type II SS become different, leading to inconsistency between ANOVA F-test and t-tests.
  • V[bk]\mathbb{V}[b_{k}] inflates.

上边都在说设计矩阵的事,更根本地,是不是应该考虑随机变量 X1,…,Xp−1X_{1},\dots,X_{p-1} 的协方差矩阵?即使它们都不相关(也就是所谓的正交),也仍然有可能生成完美共线性的设计矩阵。这设计矩阵只是表面。应该区分总体与样本的视角,上面都是样本的视角。

Remedy

Reducing Multicollinearity

  • Collect additional data under different experimental or observational conditions (add rows to XX).
  • Principal component analysis (PCA)
  • Variable transformation

Comments on PCR (PCA + Regression)

  • Bad interpretability
  • The whole process of PCA doesn't consider YY. What if the last PC contains a variable which is perfect linear with YY?

Omitting a Relevant Explanatory Variable

If the true model is

Y=β0+βXX+βWW+εY= \beta_{0}+\beta_{X}X+\beta_{W}W+\varepsilon

Let's see what will happen to our estimation if WW is omitted.

Original design matrix D=[1xw]D=\begin{bmatrix}\boldsymbol{1} & x & w\end{bmatrix}. The estimation is

b=(DTD)−1DTY∼N(β,σ2(DTD)−1)b=(D^TD)^{-1}D^TY\sim N(\beta,\sigma^{2}(D^TD)^{-1})

Drop the column ww and DD becomes D′=[1x]D'=\begin{bmatrix}\boldsymbol{1} & x\end{bmatrix}. The estimation is

b′=(D′TD′)TD′TY∼N((D′TD′)−1D′TDβ, σ2(D′TD′)−1)b'=(D'^TD')^TD'^TY\sim N\big((D'^TD')^{-1}D'^TD\beta,\ \sigma^{2}(D'^TD')^{-1}\big)

So generally bX′b'_{X} would be biased and its variance would change.


Famous example: Simpson's Paradox.

Maybe the true model contains many 0/1 variable and XX. If we conduct Y∼XY\sim X which omits all other variables. The slope of XX will be estimated with bias.

因果推断中很熟悉了。但是线性回归的视角不太一样,能否统一?两者应该有一个共同的本质的解释。

本质的解释就是忽略了重要变量。

Polynomial Regression

Sometimes we need to add terms like Xk2X_{k}^{2} into the model. But this usually comes with issue of multicollinearity.

How to address the correlation between XkX_{k} and Xk2X_{k}^{2} ? Centralization. Below is an example.

1st order 2nd order
1 1
2 4
3 9
high correlation.
1st order (after centralization) 2nd order
-1 1
0 0
1 1
low coorelation.

Check collinearity

Same model

Read from bottom to top. The first variable whose p-value is different between t-test and F-test has collinearity problem with previous variables. In this case, schrate2 has collinearity with stemp2 and sct.

Recall the meaning of t-test and type I SS.

t-test for schrate2 checks if it brings new information controlling all other variables while F-test controlling schrate and stemp without controlling stemp2 and sct.

The fact that p-values are different tells us stemp2 and sct can explained the information brought by schrate2 thus indicating collinearity.


Reduce collinearity

By centralization.

Change in ANOVA table:
Left: before centralization; Right: after centralization
If higher-order terms appear after corresponding lower-order terms, the ANOVA table won't change. The reason is the original nested models are

Y∼X1Y∼X1+X12…\begin{align} Y & \sim X_{1}\\ Y & \sim X_{1}+X_{1}^{2}\\ & \dots \end{align}

after centralization, the nested models are

Y∼X1−cY∼(X1−c)+(X1−c)2…\begin{align} Y & \sim X_{1}-c\\ Y & \sim (X_{1}-c)+(X_{1}-c)^{2} \\ & \dots \end{align}

The new information brought by the higher-order term only comes from X12X_{1}^{2}. So type II SS doesn't change.

But if the order changes, the ANOVA table will change, because the nested models after centralization are like

Y∼(X1−c)2Y∼(X1−c)2+(X1−c)…\begin{align} Y & \sim (X_{1}-c)^{2}\\ Y & \sim (X_{1}-c)^{2}+(X_{1}-c)\\ & \dots \end{align}

The first model already have information that can be brought by X1X_{1}, though we cannot independently control this 1st-order term.

以上只是直觉解释,有时间得更细致地查看 OLS 对这些模型的估计过程。(我估计永远都不会有时间)

We can add terms with higher orders such as Xk3,Xk4X_{k}^{3},X_{k}^{4}... But to them, centralization doesn't make much use. We do Gram–Schmidt orthogonalization to mitigate collinearity.

Interaction Models

Look at the slides.


10 Multicollinearity & Polynomial Regression & Interaction Models
https://wtx17.github.io/2026/11/24/Lec10-Multicollinearity-and-Polynomial-Regression-and-Interaction-Models/
作者
wtx
发布于
2026年11月24日
更新于
2026年12月2日
许可协议