Loading…

Simple Linear Regression Model

Statistics • Simple Linear Regression

View all topics
Goal: paste (x, y) data, fit the least-squares line, and visualize the scatter plot with the regression line (and optional residuals).
Use x for the explanatory (independent) variable and y for the response (dependent) variable.
Accepted formats per line: x,y or x y (commas, tabs, spaces). Header rows are allowed.
If provided, the calculator reports ŷ(x0) and the mean-response standard error (when n ≥ 3).
Controls how many labeled tick marks appear on each axis.
Residuals are vertical distances from each point to the fitted line at the same x.
Adds breathing room around the extreme data values.
Ready

Results

Rate this calculator

0.0 /5 (0 ratings)
Be the first to rate.
Your rating
You can update your rating any time.

Frequently Asked Questions

What does a simple linear regression model compute?

It finds the best-fitting straight line that predicts a response y from a single explanatory variable x using least squares. The output includes the fitted equation yhat = b0 + b1 x and measures of fit.

How are the slope and intercept found in least-squares regression?

The slope b1 is computed from how x and y vary together relative to how x varies, and the intercept b0 is then set so the line passes through the point (xbar, ybar). This ensures the fitted line matches the sample means.

What are residuals in a regression plot?

A residual is the vertical difference between an observed y value and the fitted value at the same x: e = y - yhat. Showing residuals helps visualize how far points are from the regression line.

What does R^2 mean in a simple linear regression model?

R^2 is the proportion of the total variation in y explained by the linear model. Values closer to 1 indicate a stronger linear fit, while values closer to 0 indicate a weaker linear relationship.

How do I use this calculator to predict y at a specific x0?

Enter your (x, y) data, then fill in the Predict at x0 field and click Calculate. The calculator will report yhat(x0) and the mean-response standard error when the sample size is sufficient.