Impact-Site-Verification: 1fce05f2-a6cf-4f31-8ca1-aaddc332516c

Linear Regression Calculator

Fit y = mx + b to paired data with slope, intercept, r, and r².

Clear formulas
Educational steps
Detail breakdown

Ordinary least squares regression line with equation string.

Limitation: Educational OLS—not weighted regression or robust fits.

Jump to calculator · Sources & review

How to Use the Linear Regression Calculator

Ordinary least squares regression line with equation string.

1

Open the Regression calculator and read field labels.

Match the mode

Educational OLS—not weighted regression or robust fits.

What It Calculates

Ordinary least squares regression line with equation string.

Worked Examples

Perfect line

Inputs

xText:1,2,3
yText:2,4,6

Result

y = 2x + 0

Slope 2, intercept 0.

Noisy points

Inputs

xText:1,2,3,4,5
yText:2,4,5,4,5

Result

OLS line

r and r² in details.

Constant X fails

Inputs

xText:3,3,3
yText:1,2,3

Result

Error

Zero X variance.

Check your mode

Educational OLS—not weighted regression or robust fits.

Frequently Asked Questions

Yes. Results keep the precision shown on the page unless the engine requires integers.

Still have questions about this calculation?

Try the Calculator

Formulas

Standard definitions with assumptions noted below.

Formula

b ​=​ Σ​(​​(​x−x̄​)​​(​y−ȳ​)​​)​​/​Σ​(​x−x̄​)​²

Scientific Background

Standard statistics definitions with assumptions stated on-page. Educational only—not professional certification.

Sources & review

Linear Regression Calculator documents the references behind its formulas and assumptions. Always treat results as educational estimates, not personalized professional advice.

Last reviewed

July 22, 2026

  • Free Calculator Hub methodology

    Free Calculator Hub

    /methodology

See our methodology and corrections policy.