Skip to content

Multiple Regression Calculator

Paste a spreadsheet, choose a response and any number of predictors, and fit a multiple linear regression: coefficients with standard errors, t-tests and confidence intervals, standardized betas, R², adjusted R², the overall F test, variance inflation factors, residual diagnostics and predictions with intervals. It uses a numerically stable QR solver and runs in your browser — nothing is uploaded. Free, no sign-up.

Paste from a spreadsheet (with a header row of variable names), or separate values with tabs, commas, semicolons or spaces. Blank cells and NA count as missing. A text column with two values (yes/no, male/female) works as a 0/1 predictor.

How to Use the Multiple Regression Calculator

  1. 1. Paste your data. One row per case, one column per variable, with a header row of names. Blank cells and NA are missing; any case missing a value for a chosen variable is left out, and the page says how many.
  2. 2. Choose the response and the predictors. The response is the variable you want to predict. Tick every predictor to include. A text column with exactly two values (yes/no, treatment/control) is turned into a 0/1 predictor automatically; code any other categorical variable as 0/1 columns first.
  3. 3. Read the fit. R², adjusted R² and the overall F test say how well the predictors do together; the coefficients table says what each contributes, holding the others constant.
  4. 4. Check the diagnostics. VIFs flag collinearity, the plots show curvature and unequal spread, and the case table lists unusual observations. Predict for new values at the bottom.

What Multiple Regression Estimates

Multiple regression fits ŷ = b₀ + b₁x₁ + b₂x₂ + … + b_kx_k by ordinary least squares: it chooses the coefficients that make the sum of squared residuals as small as possible. Each slope bⱼ is a partial effect — the predicted change in y for a one-unit increase in xⱼ with every other predictor held fixed — which is why adding a predictor can change the others' coefficients, and why a predictor that matters on its own can look unimportant once a related one is in the model.

The calculator solves the problem with a Householder QR decomposition, not the textbook normal equations. Forming XᵀX squares the condition number, so with correlated predictors it can lose half its digits before the solve even starts. If one predictor is an exact linear combination of the others, it is flagged as aliased and left out, as R's lm does; the others are still estimated.

R²

1 − SSE ÷ SST

Adjusted R²

1 − (1 − R²)(n − 1) ÷ (n − k − 1)

F

(R² ÷ k) ÷ ((1 − R²) ÷ (n − k − 1))

VIFⱼ

1 ÷ (1 − R²ⱼ), R²ⱼ from regressing xⱼ on the other predictors

Worked Example

The example data are the 1974 Motor Trend road tests of 32 cars (R's mtcars data): miles per gallon (mpg) against weight (wt, in 1,000 lb), gross horsepower (hp) and engine displacement (disp, in cubic inches). The fitted equation is ŷ = 37.1055 − 3.8009 × wt − 0.0312 × hp − 0.0009 × disp, with R² = 0.8268, adjusted R² = 0.8083, residual standard error 2.639 mpg and F(3, 28) = 44.57, p < .0001.

  • Weight is the clear driver: each extra 1,000 lb lowers predicted mpg by 3.80 (SE 1.07, t = −3.56, p = .0013, 95% CI −5.98 to −1.62), at fixed horsepower and displacement.
  • Horsepower adds a smaller, still significant effect: −0.0312 mpg per hp (p = .0110).
  • Displacement contributes nothing once the others are in (p = .9285), though it correlates strongly with mpg alone. Its VIF of 7.32 shows why: 86% of its variance is shared with weight and horsepower. Adding it left R² unchanged at four decimals (0.8268) but lowered adjusted R² from 0.8148 to 0.8083 — the penalty for a useless predictor.
  • Prediction. For a car with wt = 3, hp = 150 and disp = 200 the model gives 20.84 mpg: 95% CI 19.78 to 21.90 for the average car of that kind, and a 95% prediction interval of 15.33 to 26.35 for one particular car.

Common Problems

  • Collinearity. A VIF above 5 means a predictor is largely explained by the others; above 10 the coefficients are unstable. The model still predicts well, but individual effects become unreadable. Drop or combine overlapping predictors.
  • Too many predictors for too few cases. A common guideline is at least 10–20 cases per predictor. With a small n, R² is inflated, and adjusted R² and the F test are your protection.
  • Extrapolation. The model describes the region your data cover. The prediction panel warns when new values fall outside it.
  • Outliers and leverage. One case with an unusual predictor combination can pull the fit; the case table flags large residuals, high leverage and large Cook's distance.

Frequently Asked Questions

How do I interpret the coefficients in multiple regression?
Each coefficient is the expected change in the response for a one-unit increase in that predictor with all other predictors held constant. The intercept is the predicted response when every predictor is zero, which is meaningful only if zero is a realistic value. Use the standardized β to compare predictors measured in different units.
What is the difference between R² and adjusted R²?
R² never falls when you add a predictor, even a useless one, so it flatters big models. Adjusted R² charges for each extra predictor and can fall, making it the better yardstick for comparing models with different numbers of predictors. If the two differ greatly, you probably have too many predictors for your sample size.
What is a good VIF value?
A VIF of 1 means a predictor is uncorrelated with the rest. Under 5 is usually fine, 5–10 is moderate collinearity, and above 10 is serious by the common rule of thumb. These cut-offs are conventions, and the right response depends on whether you need the individual coefficients or only the predictions.
How many observations do I need for multiple regression?
A rough minimum is 10–20 cases per predictor, and more if you expect small effects or want stable coefficients. Technically you need at least k + 2 complete cases to get residual degrees of freedom, but a model fitted to so few will be badly overfitted.
Can I use categorical predictors?
Yes, after coding them as numbers. A two-level variable can be pasted as text (yes/no) and is coded 0/1 for you. A variable with more levels needs one 0/1 column for each level except a reference level — for three groups, two columns — which you create in your spreadsheet.
Why is my model significant when no individual predictor is?
That is the classic sign of collinearity. The F test asks whether the predictors help jointly, while each t-test asks whether one adds anything beyond the rest. When predictors overlap heavily, none adds much alone even though together they explain a lot. Check the VIFs.

Related Tools

More in Statistics Calculators

See all Statistics Calculators