# Partial R2 and contribution of Regressors

I asked a similar question on Cross Validated, but got no answer. The following question is sufficiently different.

Consider the following deterministic relationship:$$Y_{t}=C_{t}+I_{t}+G_{t}+(X_{t}-M_{t})$$

If we run an OLS regression of Y on the covariates, of course, we get an $R^{2}$ of 1, and the vector of coefficients equal to their population counterparts, i.e. $$\hat{\beta}= \beta=1$$

Now, this means the marginal effect of each regressor is constant. However, the contribution of each regressor depends on its relative variance to y. In fact, in the univariate case, it can be shown that:$$R^{2}=\beta^{2}\frac{var(x)}{var(y)}$$ which shows that even when the marginal effect of $x$ on $y$ is large, its contribution in the partial $R^{2}$ sense is high only when it varies a lot, causing y to vary with it as well.

Now, consider the same above expression:$$Y_{t}=C_{t}+I_{t}+G_{t}+(X_{t}-M_{t})$$

Let us divide both sides by $Y_{t}$ for the entire vector of coefficients and the design matrix.

We get:$$1=\frac{C_{t}}{Y_{t}}+\frac{I_{t}}{Y_{t}}+\frac{G_{t}}{Y_{t}}+\frac{(X_{t}-M_{t})}{Y_{t}}$$

This holds for each realization of $Y_{t}$ and the design matrix by construction. Now, each regressor here is the relative contribution (which we can multiply by 100 to get percentage contribution) to the dependent variable.

Now that we have the relative contribution for each regressor for each observation, we can get the mean contribution of the regressor across observations.

I ran some simulations, and found that the mean contribution of each regressor is close, but not exactly equal to the partial $R^{2}$ of each regressor. Is there any relationship between them? Intuitively, they should be the same, right? Thanks a lot!

• I think this question would be more appropriate if posted in cross-validated. Jan 28, 2016 at 8:27
• I don't see how you can get a partial $R^2$ less than one for your fully deterministic model. See also the first answer in this post.
– tdm
Jul 5, 2021 at 14:33
• The question is less about what the definition of a partial R2 is, and more about the relationship between Partial R2 and percentage contribution (deterministic or not) Jul 5, 2021 at 23:32

I'm a little baffled by your question. I've made a simple simulation, data attached:

sum x1  x2  x3  x1_proportion   x2_proportion   x3_proportion   ones
1.44975 .884738 .331214 .233797 .6102698    .2284629    .1612673    1
1.75989 .793748 .655205 .310937 .4510212    .3722992    .1766796    1
1.35571 .462276 .882351 .011085 .3409837    .6508396    .0081768    1
1.63689 .002848 .708656 .925386 .0017398    .4329283    .565332     1
1.44575 .862857 .256457 .326439 .5968218    .1773864    .2257918    1
2.10639 .59055  .964992 .550847 .2803613    .4581261    .2615126    1
1.34527 .180885 .497332 .667048 .1344604    .3696907    .4958489    1
1.97426 .299043 .831939 .843283 .1514706    .4213918    .4271376    1
1.7669  .559657 .268161 .939079 .3167457    .1517697    .5314847    1
1.58345 .916163 .520577 .146706 .5785881    .3287623    .0926496    1
1.77596 .832321 .670544 .273091 .4686608    .3775677    .1537714    1
1.89561 .779795 .756137 .359681 .4113679    .398888     .1897441    1
.784696 .000545 .63612  .148031 .0006939    .810658     .1886481    1
1.63006 .25147  .58731  .791278 .1542705    .3603002    .4854293    1
1.8412  .526846 .327903 .986448 .2861431    .1780925    .5357644    1
1.52932 .627659 .802862 .098797 .4104179    .5249804    .0646017    1


Then in Stata (or whatever you want)

reg sum x1 x2 x3

obtains 1's for all $$\beta$$'s like anticipated and rounding error to 0 for the constant. $$R^2$$'s are all 1. But

reg ones x1_proportion x2_proportion x3_proportion, noconst

Obtains, again, all $$\beta$$s are 1. And if you allow the constant, you will get simply 1 for the constant and 0 for all $$\beta$$s. In either case, again, $$R^2$$'s are all 1.

I think you have some confusion about the meaning of regression (or I am not understanding the question) here, so I will dig deeper and speculate a bit. I think you actually want:

... That x1 represents, on average 32.4% of the "sum" variable, with a standard deviation of 19.6%

• The question was- the relationship between these mean variables, and the partial R2 of each of these regressors. In other words, how is the 0.324 in row 1 related to a regression of y on x1(tilde), where x1(tilde) represents the residual of an auxiliary regression of x1 on x2 and x2 (i.e. orthogonalized x1) Jul 5, 2021 at 21:40
• ^ the R2 obtained by a regression of y on x(tilde) Jul 5, 2021 at 23:31
• @RegressForward: how do you even obtain an $R^2$ in your regression of "ones" over the rest, with "ones" having zero variation?
– BrsG
Jul 6, 2021 at 19:56
• Might be a short cut in Stata that when the numerator is the same size as the denominator it returns 1, even if the denominator is 0. Jul 6, 2021 at 20:40
• @RegressForward The regression would just be the regression of Y on C, I, G and X-M. Notice that we would get a coefficient of 1, as you indicated. What I am comparing is not a regression of 1 on the contribution of each of the components C, I, G and X-M, but rather, the average contribution of say, C to Y (hence E[C/Y] across observations), to the partial R2 obtained by a regression of Y on C (or the R2 of Y on C, when C and other components are independent). Jul 7, 2021 at 18:52