Least-squares regression
MathDefinition
A statistical method that finds the line of best fit by minimizing the sum of the squared vertical distances (residuals) between the data points and the line. The resulting equation is ŷ = a + bx, where b is the slope and a is the y-intercept.
How It Works
- Calculate the means of x and y.
- Compute the slope: b = r(sᵧ/sₓ), where r is the correlation coefficient.
- Calculate the y-intercept: a = ȳ − bx̄.
- Write the equation ŷ = a + bx.
- Interpret slope and intercept in context.
Examples
- Predicting a student's test score based on hours studied
- Modeling the relationship between advertising spending and sales
- Estimating home price based on square footage
Key Fact
Slope: b = r(sᵧ/sₓ), y-intercept: a = ȳ − bx̄
Study This Concept
Practice least-squares regression with free review games in these units: