The Wikipedia page on R2 says $R^2$ can take on a value greater than 1. I don't see how this is possible.

Values of $R^2$ outside the range 0 to 1 can occur where it is used to measure the agreement between observed and modeled values and where the "modeled" values are not obtained by linear regression and depending on which formulation of $R^2$ is used. If the first formula above is used, values can be less than zero. If the second expression is used, values can be greater than one.

That quote refers to the "second expression" but I don't see a second expression on the page.

Is there any scenario where $R^2$ can be greater than 1? I am thinking about this question for nonlinear regression, but would like to get a general answer.

[For someone looking at this page with the opposite question in mind: Yes; $R^2$ can be negative. This happens when you fit a model that fits the data worse than a horizontal line. This would usually be due to a mistake in selecting a model or constraints.]

  • 6
    $\begingroup$ This issue has already been treated at least once on this website stats.stackexchange.com/questions/251337 and I imagine that there are more questions that relate to it or completely explain it. $$ SST (total) = RSS (model) + SSE (error) $$ $SS_t>SS_e$, this is only true in general if the model includes an intercept and if the mean of the error/residual is 0. If $R^2$ relates, most simply, to correlation, and there are no corrections, then it must indeed be no greater than 1. It is just that it is not always calculated in the same way as a correlation. $\endgroup$ – Sextus Empiricus Mar 16 '18 at 23:28
  • 1
    $\begingroup$ So you have the two expressions: $$R^2 = 1- SS_e/SS_t = SS_m/SS_t$$ it is possible that $SS_m>SS_t$ $\endgroup$ – Sextus Empiricus Mar 16 '18 at 23:37
  • $\begingroup$ I calculate R-squared as "1.0 - (absolute_error_variance / dependent_data_variance)" and since the absolute error variance cannot be less than zero, in my calculations the maximum value of R-squared is 1.0 $\endgroup$ – James Phillips Mar 17 '18 at 0:59
  • 2
    $\begingroup$ It's quirks like these that hold me to thinking that $R^2$ is best taken in general to be the square of the correlation between observed and predicted. $\endgroup$ – Nick Cox Mar 19 '18 at 18:54
  • $\begingroup$ If R squared more than one that means 1+1 is more than 2 $\endgroup$ – Ibrahim Jan 17 '19 at 23:26

I found the answer, so will post the answer to my question. As Martijn pointed out, with linear regression you can compute $R^2$ by two equivalent expressions:

$R^2 = 1- SS_e/SS_t = SS_m/SS_t$

With nonlinear regression, you cannot sum the sum-of-squares of residuals and sum-of-squares of the regression to obtain the total sum-of-squares. That equation is simply not true. So the equation above is not right. Those two experessions compute two different values for $R^2$.

The only equation that makes sense and is (I think) universally used is:

$R^2 = 1- SS_e/SS_t$

Its value is never greater than 1.0, but it can be negative when you fit the wrong model (or wrong constraints) so the $SS_e$ (sum-of-squares of residuals) is greater than $SS_t$ (sum of squares of the difference between actual and mean Y values).

The other equation is not used with nonlinear regression:

$R^2 = SS_m/SS_t$

But if this equation were used, it results in $R^2$ greater than 1.0 in cases where the model fits the data really poorly so $SS_m$ is larger than $SS_t$. This happens when the fit of the model is worse than the fit of a horizontal line, the same cases that lead to $R^2$<0 with the other equation.

Bottom line: $R^2$ can be greater than 1.0 only when an invalid (or nonstandard) equation is used to compute $R^2$ and when the chosen model (with constraints, if any) fits the data really poorly, worse than the fit of a horizontal line.


By definition, $R^2 = 1 - SS_e/SS_t$ where both SS-terms are a sum of squares and thus nonnegative. The maximum is attained at $SS_e=0$ resulting in $R^2=1$.

  • 1
    $\begingroup$ This is not true in general, and only holds when the model variance is less than the error variance. As an example, take a linear regression without an intercept-coefficient. $\endgroup$ – Alex R. Mar 19 '18 at 19:05
  • $\begingroup$ @AlexR. See Harveys Answer (much better than mine btw) - this only applies if you use another definition of $R^2$. $\endgroup$ – AlexR Mar 19 '18 at 19:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.