Linear Regression Calculator
Type pairs of numbers to find the straight line that fits them best, then predict a Y number from a new X.
1 Paste your text and pick the options
2 Your answer
Your answer shows here as you type.
How to use the Linear Regression Calculator
- Type your X numbers, separated by commas.
- Type the Y number that goes with each X, in the same order.
- Type the X you want to predict from. The line and the prediction show straight away.
Frequently asked questions
What is a best-fit line?
It is the straight line that comes closest to all the points. It is found by making the total distance from the points as small as possible.
What does how well the line fits mean?
It is the share of the ups and downs in Y that the line explains. 100% means every point sits exactly on the line.
Wrote something with AI? Slop Monkey rewrites it so it sounds like you, and keeps your facts.