What R-Squared Describes
A multiple regression model can summarize how a response varies across the observations used to fit it. R-squared is one measure of that summary: it compares the variation left in the residuals with the response’s total variation around its sample mean. Because adding predictors can improve this in-sample fit even when the added predictors contribute little, adjusted R-squared also accounts for the number of fitted slope terms.
Both measures describe fit for a particular response, set of observations, and fitted model. They do not establish that predictors cause changes in the response, and neither measure alone determines whether a model is useful for prediction.
Here \(k\) counts the slope coefficients, not the intercept. It counts each coefficient used for a quantitative predictor or indicator term; for a categorical predictor represented by several indicators, each indicator coefficient is a slope term. The adjustment formula needs positive residual degrees of freedom, so it is undefined if \(n-k-1=0\). The ordinary \(R^2\) calculation requires \(SST>0\), meaning the observed response values are not all identical.
The sums of squares use squared response units, so their ratios and both R-squared measures have no units. The calculations themselves do not require a normality assumption. They do require the stated intercept-model setup for the familiar sums-of-squares decomposition and interpretations below; assessing regression assumptions for inference is a separate task.
Interpreting R-Squared
For a least-squares model with an intercept, \(R^2\) is the fraction of the observed response variation around \(\bar{y}\) that is accounted for by differences in the fitted values. For example, an \(R^2\) of \(0.70\) means that 70% of the total variation in the response values in this data set is represented by variation in the model’s fitted values. The remaining 30% is the fraction represented by residual variation.
This is an in-sample description, not a statement that the model explains 70% of every individual response, or that 70% of the response is caused by the predictors. A high value can occur even if the model is poorly specified or performs badly for new observations; a low value does not by itself establish that a fitted relationship is unimportant.
Worked Example: Interpreting R-Squared in Context
Suppose a hypothetical model predicts the turnaround time, in hours, for 30 laboratory orders from two predictors: the number of tests ordered and the staffing level. The model includes an intercept, is full rank, and has \(SST=120\) and \(SSE=36\), measured in squared hours. Thus \(SST>0\), \(n=30\), \(k=2\), and the residual degrees of freedom are \(30-2-1=27>0\).
Ordinary R-squared. Substituting the sums of squares gives:
For these 30 observed orders, 70.0% of the variation in turnaround times around their sample mean is accounted for by variation in the fitted values from this model. This does not mean that the predictors caused 70.0% of each order’s turnaround time.
Adjusted R-squared. The model has positive residual degrees of freedom, so the adjustment is defined:
The adjusted value is 0.6778, or about 67.8% on the same numerical scale. It is a degrees-of-freedom-adjusted fit summary, not a second direct fraction of variation with exactly the same interpretation as ordinary \(R^2\).
Why Adjusted R-Squared Has a Penalty
Ordinary \(R^2\) cannot decrease when a predictor is added to a model fit by least squares to the same observations, provided both models include an intercept. The expanded model can always reproduce the old fitted values by assigning a coefficient of zero to the added predictor. Since least squares chooses coefficients to minimize \(SSE\), the expanded model’s \(SSE\) cannot be larger. The same data have the same \(SST\), so a smaller or unchanged \(SSE\) implies a larger or unchanged \(R^2=1-SSE/SST\).
The adjusted measure accounts for model size by comparing two variance estimates: the residual mean square \(SSE/(n-k-1)\), and the sample variance of the response \(SST/(n-1)\). It subtracts their ratio from 1. Adding slope terms uses up residual degrees of freedom, so a modest improvement in \(SSE\) need not compensate for the penalty. As a result, adjusted R-squared can fall when ordinary R-squared rises.
Worked Example: Comparing Two Nested Models
Suppose hypothetical data contain turnaround times for the same 24 clinic days. Two full-rank models with intercepts are fit to those days. A smaller model has \(k=2\) slope terms and \(SSE=80\); a larger model adds one predictor, has \(k=3\), and \(SSE=79\). For both models, \(SST=200\). Since \(n=24\), each has positive residual degrees of freedom: 21 for the smaller model and 20 for the larger one.
For the smaller model:
For the larger model:
Ordinary \(R^2\) rises by 0.0050 because the larger model reduces \(SSE\) by one squared hour. Adjusted R-squared instead falls, from 0.5619 to 0.5458. For these models and observations, that small improvement in residual fit does not outweigh the adjustment for the additional slope term. This comparison does not test whether the added predictor has a statistically significant coefficient; that is a different question.
A Short Justification of the Sums-of-Squares Decomposition
The familiar interpretation of \(R^2\) as the proportion represented by fitted-value variation follows from the intercept and least-squares conditions. Write each observation’s deviation from the response mean as the sum of a fitted-value deviation and a residual:
Squaring and summing over observations gives a cross-product term. In least squares with an intercept, the residuals sum to zero and are orthogonal to every fitted value. Therefore they are also orthogonal to the fitted values after subtracting their mean, and the cross-product is zero:
Consequently, the squared deviations split into fitted-value variation plus residual variation:
Dividing by \(SST>0\) shows that \(SSR/SST=1-SSE/SST=R^2\). This identity depends on the intercept-model setup; without an intercept, the usual centered \(SST\) decomposition and interpretation need not hold.
Worked Example: When Adjusted R-Squared Is Negative
Consider a hypothetical full-rank regression with an intercept, fitted to 12 observations of weekly demand. It has three slope terms, \(SST=55\), and \(SSE=50\), in squared units of demand. Here \(SST>0\) and the residual degrees of freedom are \(12-3-1=8>0\), so both measures are defined.
Ordinary R-squared is:
Adjusted R-squared is:
The negative adjusted value is permitted. It indicates that the residual mean square, \(50/8=6.25\), exceeds the response sample variance, \(55/11=5\). It does not mean that ordinary \(R^2\) is negative: ordinary \(R^2\) is 0.09091 here. Nor does the negative adjusted value mean that the model has a negative causal effect.
Using the Measures Carefully
R-squared and adjusted R-squared are useful summaries, but they answer limited questions. R-squared describes the observed fit; adjusted R-squared modifies that summary to account for how many slope terms were estimated relative to the sample size. Neither is a universal measure of model quality. In particular, a higher adjusted value is not proof that the model’s assumptions are correct, that its coefficients are meaningful, or that it will predict new responses well.
Comparisons are most interpretable when models use the same response and the same observations. If the observations differ, their \(SST\) values and response variation may differ as well, making the two summaries less directly comparable. Predictor choice, study design, residual patterns, and the intended use of the model matter in addition to these fit measures.
Common Mistakes
- Calling R-squared a causal percentage. The correction is to say that it summarizes variation in the observed responses represented by fitted values; it does not assign causal responsibility.
- Assuming adjusted R-squared must rise when a predictor is added. Ordinary \(R^2\) cannot fall for nested least-squares models on the same observations, but adjusted \(R^2\) can fall because its degrees-of-freedom penalty changes.
- Treating adjusted R-squared as an ordinary percentage explained. It is a penalized fit summary and can even be negative, so it is not always a literal proportion of observed variation.
- Ignoring the denominator conditions. Adjusted R-squared is undefined when \(n-k-1=0\); verify positive residual degrees of freedom before applying its formula.
- Using one measure to declare a model best. Fit summaries alone do not establish sound assumptions, meaningful effects, or good predictive performance on new data.
Check Your Understanding
Answer each question using the definitions and conditions in this tutorial.
- A least-squares model with an intercept has \(SST=90\) and \(SSE=27\). What is \(R^2\), and what does it mean in context if the response is measured in minutes?
- A model has \(n=18\) observations and \(k=4\) slope terms. What are its residual degrees of freedom, and is the adjusted R-squared formula defined?
- Why can ordinary R-squared not decrease when a predictor is added to a nested least-squares model fitted to the same observations?
- Can adjusted R-squared be smaller than zero even when ordinary R-squared is nonnegative? Explain briefly.
- Does a larger R-squared establish that the predictors caused the observed response differences? Why or why not?