SSE = 20, SST = 100
R² = 1 − 0.2
0.8.
The coefficient of determination is , the fraction of the variation in explained by the regression. For a straight-line fit it equals the square of the correlation, .
This page is easier if you are comfortable with:
Take , . The mean of is 4, so . The slope is , and the residual sum of squares is . Hence , and , the correlation (the correlation coefficient) of the data.
So 60% of the variation of is explained by and 40% is left in the residuals (the residual variance of a simple regression). The line itself is the least-squares line (the regression line, least squares). The same decomposition is the ANOVA table (ANOVA).
never decreases when predictors are added, so for model comparison use adjusted or information criteria (AIC and BIC). A high does not prove a causal link or that the straight-line model is right: always look at residuals. For several predictors see multiple regression.
R squared tells what fraction of the variation in y is explained by the fitted model.
The line passes through the mean point and explains 60% of the variation.
These examples are worked by hand, step by step, so you can compare your own working.
Find for , .
Find from , , .
Find from , , .
A few situations come up again and again. Knowing them saves time and helps you spot answers that cannot be right.
R² = 1 − 0.2
0.8.
R² = r²
0.81.
fit y = −0.667 + 1.5x
SSE = 0.1667.
1 − 0.1667/4.6667
0.9643.
R² = 1 − SSE/SST is the fraction of variation in y explained by the fit. For simple linear regression R² = r².
SSE = 20, SST = 100. Find R².
r = 0.9. Find R².
Residuals 1/6, −1/3, 1/6. Find SSE.
SST = 14/3. Find R².
wrong ✗
R² = r² ✓
Square.
wrong ✗
only fit ✓
No causation.
unexplained ✗
1 − SSE/SST ✓
Explained.
possible with no intercept ✗
otherwise ≥ 0 ✓
Check model.
Try each one on paper, then open the answer. Use the solver above to see the full working.
0.9
0.25
0.75
0.64
1
0.2
Unlimited fresh questions with instant marking. Choose a level, work it out on paper, then type your answer.
Solve: …
The fraction of variance explained.
1 − SSE/SST.
R² = r² for one predictor.
No; check residuals.
correlation coefficient.
multiple regression.
More in Advanced statistics and stochastic processes and the formula sheets.