Topics Covered
Adding Predictors
Extend lm() with multiple X variables and interpret each coefficient while controlling for the rest.
Dummy Coding
How R represents categorical variables behind the scenes and what the reference level means.
Model Comparison
Use AIC, adjusted R², and anova() to decide whether an extra predictor earns its place.
Key Concepts
- Partial regression coefficients — the unique contribution of each predictor
- Multicollinearity: when predictors are too correlated and VIF flags trouble
- Categorical predictors with 3+ levels: contrasts and how to set them
- The ANOVA table as a special case of multiple regression
Homework
- Build a multiple regression with one continuous and one categorical predictor
- Check VIF for multicollinearity and interpret each coefficient
- Compare nested models using anova() and report the best-fitting model