Skip to content

Multiple Linear Regression Calculator

Fit a linear model with two or more predictors at once, so each coefficient shows a predictor's association with the outcome after adjusting for every other predictor in the model, not its association in isolation.

What this answers

This calculator answers "how does this outcome relate to each predictor, holding the other predictors constant?" a materially different and usually more useful question than fitting a separate simple regression for each predictor one at a time, since predictors are rarely independent of each other in real data.

How it is calculated

Coefficients are estimated by ordinary least squares, solved via the normal equations using matrix algebra (a design matrix with an intercept column, then beta equals the inverse of X-transpose-X times X-transpose-y). Each coefficient's standard error, t statistic, and p-value test whether that specific predictor's adjusted association is distinguishable from zero. Adjusted R-squared corrects the raw R-squared for the number of predictors used, since raw R-squared mechanically increases every time a predictor is added, useful or not.

Worked example

For an outcome built exactly as 1 plus 2 times x1 plus 3 times x2, this calculator recovers an intercept of 1, a coefficient of 2 for x1, and a coefficient of 3 for x2, exactly, with an R-squared of 1, confirming the fitting procedure against data with a known, exact answer.

Assumption audit

Calculated from your data: every coefficient, its standard error, t statistic, and p-value, plus R-squared, adjusted R-squared, and the overall F-test, and whether your predictors are exactly or near-exactly collinear (which blocks the calculation entirely).
Evidence to review: whether your predictors are highly correlated with each other; use the Multicollinearity VIF Calculator to check, since severe collinearity inflates coefficient standard errors and can make individually meaningful predictors look statistically indistinguishable from zero.
You must verify: that the linear functional form is appropriate for every predictor, that observations are independent, and that no important predictor was omitted, since an omitted variable correlated with both an included predictor and the outcome will bias that predictor's coefficient.

What this result does not mean

A significant coefficient means that predictor's adjusted association with the outcome is unlikely to be exactly zero given this model, not that it causes the outcome, and not that it is the most important predictor; comparing standardized coefficients or effect sizes directly answers importance better than comparing raw p-values or coefficient sizes on different scales.

Limitations

This calculator requires at least one more observation than the number of parameters (predictors plus the intercept) and rejects predictors that are exactly or near-exactly collinear, since the underlying matrix becomes numerically unstable to invert in that case.