{
  "id": "adjusted-r-squared",
  "title": "Adjusted R-squared",
  "lang": "en",
  "source_lang": "en",
  "summary": "Adjusted R-squared measures regression fit while accounting for the number of fitted parameters relative to the sample size.",
  "category": "mathematics",
  "subcategory": "probability-statistics",
  "type": "concept",
  "aliases": [
    "Adjusted coefficient of determination",
    "Adjusted R²",
    "Adjusted R-square"
  ],
  "generated_at": "2026-11-04",
  "model": "pro/gpt-6.1-sol",
  "url": "https://aiwiki.page/en/adjusted-r-squared/",
  "translations": {
    "zh-Hans": {
      "url": "https://aiwiki.page/zh/adjusted-r-squared/",
      "json": "https://aiwiki.page/zh/adjusted-r-squared.json"
    }
  },
  "sections": [
    {
      "heading": "",
      "text": "Adjusted R-squared, usually written \\(\\bar R^2\\) or \\(R_{\\mathrm{adj}}^2\\), is a measure of fit for a linear regression model that adjusts the ordinary coefficient of determination for the number of parameters estimated. Unlike ordinary \\(R^2\\), which cannot decrease when predictors are added to an ordinary least-squares model fitted to the same observations, adjusted \\(R^2\\) can decrease. It therefore provides a way to compare explanatory fit while penalizing the inclusion of additional predictors."
    },
    {
      "heading": "Definition",
      "text": "For a regression fitted by ordinary least squares with an intercept, let:\n\n- \\(n\\) be the number of observations;\n- \\(k\\) be the number of estimated slope coefficients, excluding the intercept;\n- \\(y_i\\) be the observed response;\n- \\(\\hat y_i\\) be the fitted response;\n- \\(\\bar y\\) be the sample mean of the response.\n\nDefine the residual sum of squares and total sum of squares as\n\n\\[\\mathrm{SSE}=\\sum_{i=1}^{n}(y_i-\\hat y_i)^2, \\qquad \\mathrm{SST}=\\sum_{i=1}^{n}(y_i-\\bar y)^2.\\]\n\nOrdinary \\(R^2\\) is\n\n\\[R^2=1-\\frac{\\mathrm{SSE}}{\\mathrm{SST}}.\\]\n\nAdjusted \\(R^2\\) is\n\n\\[\\boxed{ \\bar R^2 = 1-\\frac{\\mathrm{SSE}/(n-k-1)} {\\mathrm{SST}/(n-1)} = 1-(1-R^2)\\frac{n-1}{n-k-1} }.\\]\n\nThis definition requires \\(\\mathrm{SST}>0\\) and positive residual degrees of freedom, \\(n-k-1>0\\). If the response is constant, the centered total sum of squares is zero and the usual statistic is undefined.\n\nThe parameter count refers to estimated coefficients rather than named variables. A categorical predictor represented by several indicator columns, or a polynomial predictor represented by several powers, can contribute more than one coefficient. If the design matrix is rank-deficient, residual degrees of freedom are \\(n-r\\), where \\(r\\) is its rank; with an intercept, \\(r-1\\) replaces \\(k\\)."
    },
    {
      "heading": "Statistical interpretation",
      "text": "The adjustment compares two quantities measured on the scale of variance:\n\n\\[s_e^2=\\frac{\\mathrm{SSE}}{n-k-1}, \\qquad s_y^2=\\frac{\\mathrm{SST}}{n-1}.\\]\n\nThus,\n\n\\[\\bar R^2=1-\\frac{s_e^2}{s_y^2}.\\]\n\nHere, \\(s_y^2\\) is the sample variance of the response. Under a correctly specified linear model with zero-mean, uncorrelated errors having a common variance, \\(s_e^2\\) is an unbiased estimator of the error variance.\n\nOrdinary \\(R^2\\) rewards every reduction in training residuals, including reductions obtained by fitting random variation. Adjusted \\(R^2\\) counteracts this by dividing the residual sum of squares by the degrees of freedom remaining after fitting the model.\n\nDespite this interpretation, adjusted \\(R^2\\) is not literally a decomposition of observed variation into explained and unexplained fractions. Nor is it, in general, an exactly unbiased estimator of a population coefficient of determination. Unbiasedness of individual variance estimates does not imply unbiasedness of their ratio."
    },
    {
      "heading": "Behavior and range",
      "text": "For an ordinary least-squares model with an intercept:\n\n- \\(\\bar R^2\\leq R^2\\).\n- An intercept-only model has \\(R^2=\\bar R^2=0\\).\n- A perfect fit has \\(\\bar R^2=1\\), provided positive residual degrees of freedom remain.\n- Adjusted \\(R^2\\) can be negative.\n- With a fixed number of predictors, the adjustment becomes smaller as the sample size increases.\n\nThe gap between the two measures is\n\n\\[R^2-\\bar R^2 = \\frac{k(1-R^2)}{n-k-1}.\\]\n\nA negative adjusted \\(R^2\\) means that the residual variance estimate exceeds the sample variance of the response. It does not mean that a negative proportion of variation has literally been explained.\n\nFor a fixed dataset, maximizing adjusted \\(R^2\\) is equivalent to minimizing the residual mean square, \\(\\mathrm{SSE}/(n-k-1)\\)."
    },
    {
      "heading": "What happens when predictors are added?",
      "text": "Consider two nested models fitted to the same observations. The reduced model has \\(k\\) slope coefficients, and the full model adds \\(q\\) independently estimable coefficients. Write their residual sums of squares as \\(\\mathrm{SSE}_R\\) and \\(\\mathrm{SSE}_F\\).\n\nFor a full model with positive residual sum of squares, define the partial \\(F\\)-statistic as\n\n\\[F= \\frac{(\\mathrm{SSE}_R-\\mathrm{SSE}_F)/q} {\\mathrm{SSE}_F/(n-k-q-1)}.\\]\n\nThen\n\n\\[\\bar R_F^2>\\bar R_R^2 \\quad\\Longleftrightarrow\\quad F>1.\\]\n\nThus, adjusted \\(R^2\\) increases only when the improvement per added parameter exceeds the full model’s residual mean square. This relationship is algebraic; interpreting the statistic through an \\(F\\)-distribution requires additional assumptions.\n\nWhen one coefficient is added, the corresponding ordinary least-squares \\(t\\)-statistic satisfies \\(F=t^2\\). Adjusted \\(R^2\\) therefore rises when \\(|t|>1\\). This is not equivalent to passing a conventional hypothesis test at the 5% significance level. Maximizing adjusted \\(R^2\\) can consequently retain predictors that would not meet that testing threshold."
    },
    {
      "heading": "Numerical example",
      "text": "Suppose several models are fitted to the same 100 observations:\n\nModel | Slope coefficients \\(k\\) | Ordinary \\(R^2\\) | Adjusted \\(R^2\\)\nA | 2 | 0.600 | 0.5918\nB | 3 | 0.602 | 0.5896\nC | 3 | 0.610 | 0.5978\n\nFor model A,\n\n\\[\\bar R_A^2 = 1-(1-0.600)\\frac{99}{97} \\approx 0.5918.\\]\n\nIf model B adds a predictor to model A, its small improvement in ordinary \\(R^2\\) is insufficient to offset the extra parameter. Model C provides a larger improvement and has a higher adjusted \\(R^2\\). Models B and C have the same parameter count, so their ranking by adjusted \\(R^2\\) is identical to their ranking by ordinary \\(R^2\\)."
    },
    {
      "heading": "Uses and limitations",
      "text": "Adjusted \\(R^2\\) is commonly reported in regression analyses in statistics, econometrics, and other quantitative disciplines. It is useful for comparing models with different numbers of predictors, provided they use the same response, observations, and fitting convention.\n\nIts interpretation has several important limits.\n\nIt is not an out-of-sample performance measure\n\nAdjusted \\(R^2\\) is computed from the data used to fit the model. Its parameter penalty does not directly measure prediction error on new observations. Searching through many models can produce an optimistically high selected value. Cross-validation or an independent test dataset addresses predictive performance more directly, using measures such as mean squared error.\n\nIt does not establish model validity or causation\n\nA high adjusted \\(R^2\\) does not demonstrate that the functional form is correct, error assumptions hold, or influential observations are absent. It also does not establish causation: omitted variables, confounding, and other identification problems can remain even when fit is high.\n\nComparisons require a common basis\n\nComparing adjusted \\(R^2\\) values is generally inappropriate when models use different observations or differently transformed responses. For example, a model for \\(y\\) and a model for \\(\\log y\\) measure residual variation on different scales. Changes caused by dropping observations with missing predictor values also cannot be attributed solely to the predictor set.\n\nOther model classes need different conventions\n\nWithout an intercept, some software uses an uncentered total sum of squares, \\(\\sum_i y_i^2\\), and a corresponding adjustment. Such values are not directly comparable with the centered statistic defined above.\n\nFor regularized models, such as ridge regression, the number of fitted coefficients is not generally an adequate measure of effective model complexity. Similarly, likelihood-based models such as logistic regression use various pseudo-\\(R^2\\) measures; their adjusted forms are not the same statistic as adjusted \\(R^2\\) for ordinary least squares."
    }
  ],
  "links": [
    "linear-regression",
    "coefficient-of-determination",
    "ordinary-least-squares",
    "sample-mean",
    "degrees-of-freedom",
    "matrix",
    "matrix-rank",
    "variance",
    "sample-size",
    "statistical-hypothesis-testing",
    "significance-level",
    "statistics",
    "econometrics",
    "cross-validation",
    "mean-squared-error",
    "causal-inference",
    "confounding",
    "regularization",
    "ridge-regression",
    "logistic-regression"
  ],
  "sources": [],
  "license": "https://creativecommons.org/licenses/by/4.0/"
}