Regression Foundations
A reading guide for the slides that revisit variance and standard errors — and separate the two things the word “variance” is doing.
Section one
The formulas and definitions the slides depend on, each stated as a claim.
Key concepts
Deviations are the currency of every variance.
Every sum of squares in regression is built by measuring a distance, squaring it, and adding it up. Only the reference point changes:
There are two different variances, and they answer different questions.
| Sample distribution | Sampling distribution | |
|---|---|---|
| What varies | the data | the estimate |
| Question | How spread out are the observations? | How much would my estimate move in a new sample? |
| Centered on | the center of the data | the “true” parameter |
| Measured in | standard deviations | standard errors |
| You can see it | yes — it is your data | no — it is hypothetical |
The variance of Y partitions into an explained and an unexplained part.
Total SS becomes the variance of Y. Error SS becomes the variance of the slope.
The regression line is a conditional mean.
Same sentence, one word changed. The regression line is what the mean of Y becomes once you let it depend on X.
The standard error of the slope is built out of the unexplained variance.
Or in words:
Standard error: on average, how far off is our best guess of the slope from the true slope?
The Central Limit Theorem is what makes the sampling distribution usable.
Across repeated samples the estimated slope is approximately normally distributed and centered on the true slope. That shape is what licenses:
Inference happens in the sampling distribution, not in the sample.
Section two
The mental map. How the pieces connect, and how to read the deck.
Sample variance describes your data; sampling variance describes your estimate — and the second is manufactured out of the first.
That is the subtle part. These are not two unrelated topics that happen to share the word variance. The unexplained portion of the variance in your data is the raw material the standard error is made from. Noisy data produce an unstable estimate. The deck alternates between the two on purpose: slides labeled “this is sample variance” and “this is sampling variance” are asking you to notice which one you are looking at, because the pictures look similar and the meaning is completely different.
The side-by-side slide near the end is the thesis of the lecture. Read it carefully:
Same picture-making logic, different unit of observation. In the first, a dot is a person. In the second, a dot is an entire study.
This is why the simulation slides exist. In real work you draw one sample, compute one slope, and that is all you will ever see. The sampling distribution is counterfactual — it is the spread of the estimates you would have gotten from all the samples you did not draw.
The simulations make that invisible object visible: each frame draws a new sample from the same population, fits a new line, and drops one more slope onto the sampling distribution. Watching the line jump around from sample to sample is sampling variance. The standard error is just the width of that jumping, calculated rather than simulated.
Every quantity in the deck comes from one of three distances:
| Distance | Name | Sum of squares | Becomes |
|---|---|---|---|
| yi − | deviation | Total SS | variance of Y |
| ŷi − | explained | Regression SS | model fit (R2) |
| yi − ŷi | residual | Error SS | variance of the slope |
The third row is the one this deck is really about. Everything that determines whether your result is statistically significant flows out of the residual.
Notation warning. This deck writes TSS = RSS + ESS where RSS = Regression SS and ESS = Error SS. Many textbooks use exactly the opposite (RSS = Residual, ESS = Explained). One slide reconciles it explicitly — “Error SS, same as the Residual SS.” When you see ESS in these slides, read error, not explained.
Slide 5 is doing more work than it looks like. It slices caffeine into bins and plots the average heart rate in each — 74, 78, 82, 86, 90, 95, 99, 103, 107, 111 — against a flat “mean of Y” line at 90.
The flat line is the unconditional mean: your best guess about anyone’s heart rate if you know nothing about them. The rising sequence of bin averages is the conditional mean: your best guess once you know their caffeine intake. The regression line is a smooth version of that second sequence.
Once you see it that way, the parallel interpretations fall out for free:
Regression did not introduce a new kind of dispersion. It moved the reference point from a flat line to a tilted one.
The approximation slide is worth memorizing because it tells you what to do as a researcher:
Three levers, and only three:
That last one surprises people. If everyone in your study got roughly the same dose, you cannot learn much about dosage.
The final slide is the payoff, and it is worth being able to recite:
Read left to right, this says that statistical significance is downstream of model fit. Read right to left, it says a p-value is never a standalone fact — it inherits everything from how much of Y your model failed to explain. This is also why the Central Limit Theorem appears in the middle of the deck: it is the step that turns a spread of hypothetical estimates into a probability statement.
| Slides | What they are doing | What to take away |
|---|---|---|
| 1–2 | Framing: deviations as the common currency | Every variance is squared distances from some reference point. |
| 3–6 | Sample variance, four ways | The mean, then the conditional mean, then the partition into explained and residual. |
| 7 | Partitioning the variance of Y | The formula sheet for the whole deck. Note the ESS/RSS convention. |
| 8–10 | The Central Limit Theorem and SEb1 | The standard error is the residual variance, scaled by n and the spread of X. |
| 11–12, 15 | Simulations | The sampling distribution made visible. Each frame is a study you did not run. |
| 13–14 | Back to sample variance | Deliberate whiplash. Ask yourself which variance you are looking at. |
| 16 | Sample vs sampling, side by side | The thesis slide. Two centers, two rulers. |
| 17 | Deviations vs residuals | The conditional-mean parallel. |
| 18 | Unexplained variance → p-value | The chain. Be able to recite it. |
The alternation between “this is sample variance” and “this is sampling variance” is not disorganization — it is the exercise. If you can label each slide correctly without reading the title, you have the distinction.
Section three
The four things this deck exists to settle.