Chapter 3 · Section 7

Multiple Linear Regression and Multicollinearity

Prof. Xuhu Wan

§7 — Multiple Linear Regression and Multicollinearity

Use city demographics to model annual pharmacy profit, interpret partial coefficients, and assess multicollinearity.

Pharmacy Profit: Why Use Several Predictors?

Source column Meaning and unit
Profit Annual pharmacy profit, US dollars; the outcome Y
Income City median annual salary, US dollars
Disposable Income City median income after taxes, US dollars
Birth Rate (per 1,000) Births per 1,000 residents
Soc Security (per 1,000) Social-security recipients per 1,000 residents
CV Death (per 100,000) Cardiovascular deaths per 100,000 residents
% 65 or Older Residents aged 65+, in percentage points: 14 means 14%

Location identifies a city; it is not a numerical predictor. The file contains 110 cities with observed profit and one proposed Kansas City location with no profit yet.

Read the Six-Predictor Design Table

The response is annual Profit. The design table contains an intercept column const and six demographic columns. sm.add_constant() creates the column of ones; .fit() estimates all seven coefficients together.

Partial Coefficients Have Units

Compare two otherwise identical demographic profiles. Hold the other five predictors fixed.

Input difference Difference in fitted annual profit, full model
Income higher by US$1,000 About US$599 higher
Disposable income higher by US$1,000 About US$2,535 higher
Birth rate higher by 1 birth per 1,000 About US$1,704 higher
Age 65+ share higher by 1 percentage point About US$7,714 higher

Interactive Prediction: Hold the Other Inputs Fixed

Each line keeps the other inputs fixed. Move disposable income along it, or change the age-65+ share. Both axes use USD thousands.

R-Squared versus Adjusted R-Squared

Compare Income-only and six-predictor models on the same 110 cities. Adding inputs cannot lower training R² when both models include an intercept. Adjusted R² also accounts for the number of fitted predictors; it can fall when an added input contributes too little.

Adjusted R-Squared: Allow for the Number of Predictors

\(R^2_{adj}=1-\dfrac{SSE/(n-k-1)}{SST/(n-1)}\). Here \(n=110\), \(k=6\) and \(n-k-1=103\). The intercept is estimated but is not counted in \(k\).

MLR RMSE: Allow for All Estimated Coefficients

The course uses regression RMSE \(s=\sqrt{SSE/(n-k-1)}\). Six demographic predictors and one intercept leave 103 residual degrees of freedom. Here \(s\approx\text{US}\$13,547\) per year.

What Is Multicollinearity?

Multicollinearity is linear dependence among the predictors. If one input is nearly a linear combination of the others, little independent variation remains to estimate its separate association with profit.

In these cities, social-security recipients and the share aged 65+ move closely together.

Perfect dependence: coefficients are not uniquely identifiable. Strong imperfect dependence: coefficients can be estimated but may be imprecise.

Multicollinearity: Coefficients and Standard Errors

Strong imperfect dependence makes the separate predictor associations hard to estimate.

What changes? Consequence
Coefficient estimates Small data changes can alter their size or sign; estimates depend on the other predictors included.
Standard errors Coefficient variance and SE increase, other conditions held fixed.
Numerical stability Near-perfect dependence can amplify rounding and numerical errors.

Not automatic bias: imperfect multicollinearity does not itself bias OLS under a correctly specified, full-rank model with zero conditional mean error.

Multicollinearity: Tests and Confidence Intervals

Individual t-tests and coefficient intervals depend on the coefficient SE.

What changes? Consequence
Individual t-tests Lower power; a useful predictor may have a large p-value after accounting for the others.
Coefficient confidence intervals Wider intervals can include zero and both signs.
Overall F-test and R² A significant joint test and high training R² can coexist with weak individual t-tests.

A large p-value can reflect imprecision, rather than the absence of a useful association.

Multicollinearity: Prediction and Prediction Intervals

Individual coefficients can be uncertain while their combined prediction remains precise for familiar input combinations.

Target What multicollinearity means
Point prediction Can remain stable for familiar combinations; validate accuracy on test data.
Mean-response CI Can remain narrow for familiar combinations, but widen for unusual combinations.
New-outcome PI Adds new-outcome noise to fitted-mean uncertainty; not automatically wide.

Joint support matters: familiar social-security and age-share ranges do not guarantee a familiar combination. Validate predictions on representative test data.

VIF: Predict a Predictor with the Others

For each demographic input \(X_j\), fit an auxiliary regression on the other five inputs. Then \(VIF_j=1/(1-R_j^2)\). Profit is not used in this auxiliary regression. A large value signals little variation unique to that input.

Three Predictors: What Are the Auxiliary R-Squared Values?

For a smaller VIF illustration, use Income, Disposable Income and the age-65+ share. Fit three auxiliary regressions. Each takes one of these inputs as its response and the other two as predictors. Do not use Profit.

Illustration: VIF Grows Near Dependence

The relationship is nonlinear: auxiliary R² of 0.5 gives VIF=2; 0.9 gives VIF=10; 0.99 gives VIF=100. The graph illustrates the formula rather than six estimated pharmacy VIFs.

Overall F-Test: Do the Predictors Help Together?

\(H_0:b_1=b_2=\cdots=b_6=0\) versus \(H_1\): at least one slope differs from zero. Compare the six-input profit model with an intercept-only mean-profit model. The intercept is not part of the joint null.

The F Statistic Compares Explained Variation with Noise

\(F=(SSR/k)/(SSE/(n-k-1))\). Here \(k=6\) and the denominator degrees of freedom are 103. The pharmacy fit gives \(F\approx53.12\).

Individual t-Test: Does This Input Help Given the Others?

For social-security recipients, test \(H_0:b_j=0\) against \(H_1:b_j\ne0\). The two-sided test asks whether this partial linear association differs from zero after including the other five inputs.

Overall F-Test and Individual t-Tests

A large overall F can coexist with small absolute t statistics for some inputs. The six demographics jointly help explain profit, while some separate associations remain imprecise.

In this sample, F≈53.12, while the social-security t statistic is about −0.43. The overall F-test and an individual t-test answer different questions.

If LINE Assumptions Fail: What Changes?

LINE violations: what remains usable and what needs attention Four schematic residual or error plots. A wrong mean shape can harm mean prediction and interpretation. Dependence or unequal variance need not bias OLS under zero conditional mean and full rank, but usual standard errors and inference can fail. Normal errors are not required for OLS mean point prediction, but exact small-sample t and F inference and normal-based individual prediction intervals can fail. The assumptions needed depend on whether the goal is a mean prediction, coefficient inference, or a new-outcome prediction interval. Violation · schematic What can remain usable? What needs attention? L · Wrong mean shape OLS still fits a line; it may miss the true mean. Mean prediction and interpretation can fail. Fix the mean form; robust SE cannot do this. Residual / X I · Dependent errors OLS need not be biased*. It may be less efficient. Usual SE, t/F tests and intervals may be wrong. Use dependence-aware SE and validation. Residual / time N · Nonnormal errors OLS mean point predictions do not require normal errors. Exact small-sample t/F inference may fail. Normal-based prediction intervals can be wrong. Error shape E · Unequal variance OLS need not be biased*. It may be less efficient. Usual SE, t/F tests and intervals may be wrong. Robust SE helps large-sample coefficient inference. Residual / fit Predict the mean N and E are not required. Check mean form and test accuracy. Test coefficients / CI Use suitable SE. Large-sample approximations need conditions. Predict a new outcome / PI Noise shape, spread and dependence still matter. *Assume zero mean error given all X, and uniquely identifiable coefficients (full rank). LINE checks alone establish neither these conditions nor causation.

Predict Profit with Every Required Input

The final row is the proposed Kansas City store. Supply all six demographic inputs in the same column order as the fitted design. Add the intercept column explicitly for this single new row.

In-Class Practice: A Controlled Demographic Comparison

Start with the proposed city’s inputs. Predict with the full model, then increase Disposable Income by US$1,000 while keeping every other input unchanged. Predict the difference before running. Does it equal 1,000 times that input’s fitted slope?