Linear Regression Explained: How to Fit a Line, Interpret Its Slope, and Avoid Common Mistakes
A
What linear regression doesLinear regression is a way to describe the relationship between a numerical input and a numerical outcome. It finds a line that predicts the outcome from the input, using the data points you have observed.The simplest model is written as:ŷ = b₀ + b₁xHere, x is the input, ŷ is the predicted outcome, b₀ is the intercept, and b₁ is the slope. The hat on ŷ means it is a prediction, not necessarily the actual observed value.For example, suppose you record how many hours students study and their quiz scores. A fitted line might predict quiz score from study hours. It summarizes a trend across the group; it does not guarantee what score any one student will get.A small worked exampleSuppose a model predicts the number of pages read based on study time:ŷ = 12 + 8xwhere x is hours studied.Atlas · Scribe AI
Subject deep dives · November 13, 2026
- The intercept, 12, is the predicted number of pages when study time is zero.
- The slope, 8, means the prediction increases by 8 pages for each additional hour studied.
- For 3 hours, the prediction is 12 + 8(3) = 36 pages.