Linear Regression & Correlation

Find the line of best fit, the correlation coefficient r and predictions from paired data, with sums and slope calculated. Try “best fit line for (1,2), (2,4), (3,5), (4,4), (5,6)”.

Try an example:

What you can do with the Linear Regression & Correlation

Line of best fit, r value and predictions.

Enter your values or describe the problem in the calculator above. Review the result and the explanation before using it in homework, study or practical calculations.

Example input

e.g. best fit line for (1,2), (2,4), (3,5), (4,4), (5,6)

How the Linear Regression & Correlation works

  1. Compute the means and the sums Σxy, Σx² and Σy².
  2. Slope b = Sxy ÷ Sxx and intercept a = ȳ − b·x̄.
  3. Write y = a + bx, compute r and use the line to predict.

Frequently asked questions

What does the correlation coefficient r mean?

r runs from −1 to 1: near ±1 is a strong linear relationship, near 0 is little or none.

Does correlation prove causation?

No. Two variables can move together without one causing the other.

More Statistics & Probability calculators

Browse all calculators →

Math Solver can make mistakes. Please double-check important steps and calculations.