ML 3.4Lesson outlineLesson 4 of 7 in Module 3
Multiple Linear Regression
Predict from several features with one weight each, and read a coefficient as the change in the prediction with the other features held fixed.
Video in production.
Lesson outline: Multiple Linear Regression
In this lesson12 parts
- 01What weight leaves unexplained
- 02Two features and a column of ones
- 03Two baselines
- 04From a line to a plane
- 05One weight per column
- 06The same loss
- 07Least squares for any number of features
- 08`Xw` on the hero cars
- 09Training scores
- 10Reading a coefficient
- 11NumPy, then the library
- 12Recap, your challenge, and what comes next
Builds on
This lesson stands on its own. These go deeper into what it uses.
- ML 3.1: Simple Linear Regression
- 3.3
- Maths 3.1–3.2: Matrices, the Matrix–Vector Product and the Transpose
- Python 6.3: The Estimator Pattern
- Tools 4.1–4.2 (Tools 1.6 is taken at Stage 11: Meet scikit-learn
- so `lstsq` is introduced here; checked 2026-10-14)
Key terms: Multiple Linear Regression
The words this lesson introduces, each in one line. The module’s glossary collects them all, and the AI glossary has every term across the courses.
- design matrix
- The feature table the model is fitted on, one row per sample,
X. - intercept column
- A column of ones whose weight is the intercept.
- multiple linear regression
- A linear model with more than one feature.
- normal equations
XᵀX w = Xᵀy: every partial derivative of the squared error set to zero.- coefficient
- The weight on one feature in a linear model.
- held fixed
- Read with every other feature in the model unchanged.
- standardised coefficient
- The change in the prediction for a one-standard-deviation change in the feature.
- reference category
- The category with no column of its own, which the other categories' coefficients are compared against.
Quiz: Multiple Linear Regression
Your first pick on each question is the one that counts. Getting one wrong here is how the lesson sticks.