R-squared tells you how much of the variation in an outcome a model explains, on a scale from 0 to 1. This calculator takes the sums of squares from a regression output and returns R², adjusted R², the F statistic and its p-value, so you can judge a model without redoing the regression.
How the calculation works
- R² = 1 − SSE ÷ SST, where SSE is the residual sum of squares and SST the total sum of squares
- Adjusted R² = 1 − (1 − R²) × (n − 1) ÷ (n − k − 1)
- F = (R² ÷ k) ÷ ((1 − R²) ÷ (n − k − 1)), tested against the F distribution with k and n − k − 1 degrees of freedom
- Standard error = √(SSE ÷ (n − k − 1))
Here n is the number of observations and k the number of predictors, not counting the intercept.
Example
A regression on 40 observations with 3 predictors has SSE = 120 and SST = 400. R² = 1 − 120 ÷ 400 = 0.700, so 70 % of the variation is explained. The adjusted R² is 1 − 0.3 × 39 ÷ 36 = 0.675. The F statistic is 28.0 and the p-value is far below 0.001, so the model as a whole is significant. The standard error of the regression is 1.826.
Why it matters
R-squared is the first number people read in a regression table, and it is easy to misread. The adjusted version is the fair one when you compare models with different numbers of predictors, because it stops you from rewarding a model for being bigger. The F test answers a different question: whether the predictors together explain more than chance would.
Good to know
A high R² does not mean the relationship is causal, and a low one does not mean it is unimportant: a predictor can matter even when the outcome is noisy. Outliers can inflate or deflate R² a lot, and with few observations per predictor the adjusted value is more reliable than the plain one. Check the residual plot as well. This tool is for education.
Related tools
The linear regression calculator fits a line to your data, the correlation significance calculator tests a single r, and the standard deviation calculator measures spread.