Linear Regression
Linear regression draws a straight line through dots so it can guess a number.
What it does
Linear regression draws a straight line through dots so it can guess a number.
Regression: Predicting a number • Fit: How close the line is
How it works
- Put the example dots on a chart.
- Draw a line that stays close to the dots.
- Use the line to guess a new number.
Uses & Applications
- A weather app can guess tomorrow’s temperature from past temperatures.
- A home website can estimate a house price from size and location.
- A growth chart can estimate a child’s height at a future age.
In short
It predicts numbers by drawing a best-fit line, like a growth chart.
Try it yourself
Draw a line through the clues
Imagine X is hours of practice and Y is points in a game. Find a straight line that follows the dots.
Your turn
Change one setting at a time. Reset example puts everything back.
Fit a line to observations
Step 1Why this happens