Statistics

Linear Regression Formula - Statistics

Learn the linear regression formula with examples, step-by-step guide, and calculator tools. Find the best-fit line through a set of points

The linear regression formula is a fundamental concept in statistics. Find the best-fit line through a set of points. This page provides a comprehensive guide with worked examples and practical applications.

The Formula

\[y = mx + b, \text{ where } m = \frac{\sum (x_i - \bar{x})(y_i - \bar{y})}{\sum (x_i - \bar{x})^2}\]

Variables

y
Predicted value
m
Slope
x
Independent variable
b
Y-intercept

Step-by-Step Guide

  1. 1

    Step 1: Gather your data values

  2. 2

    Step 2: Apply the formula

  3. 3

    Step 3: Perform the calculations

  4. 4

    Step 4: Interpret the result

Examples

Example 1

Example 1: [1,2,3,4,5] → y = 2x + 1, where slope m = 2, intercept b = 1

Example 2

Example 2: y = 2x + 1

Frequently Asked Questions

What is the linear regression formula?

Find the best-fit line through a set of points

How do I calculate linear regression formula?

Use the formula: y = mx + b, \text{ where } m = \frac{\sum (x_i - \bar{x})(y_i - \bar{y})}{\sum (x_i - \bar{x})^2}. Follow the steps provided above.

What tools can help with linear regression formula?

We provide online calculators: linear-regression-calculator

Related Tools

Related Insights, Formulas & Comparisons