.Purpose To see that R square is dependent on the variance of the dep variable .Simulate consumption, income and savings data for a simple regression

> set.seed(1977)
> n <- 1500
> beta.actual <- matrix(c(2, 3), ncol = 1)
> beta.sample <- cbind(rnorm(n, beta.actual[1]), rnorm(n, beta.actual[2]))
> error <- rnorm(n)
> income <- cbind(rep(1, n), seq(from = 1, to = 5, length.out = n))
> consumption <- income[, 1] * beta.sample[, 1] + income[, 2] *
+     beta.sample[, 2] + error
> savings <- income - consumption
> summary(lm(consumption ~ income + 0))
Call:
lm(formula = consumption ~ income + 0)
Residuals: Min 1Q Median 3Q Max -15.19239 -1.97241 0.02677 2.07748 13.28453
Coefficients: Estimate Std. Error t value Pr(>|t|) income1 2.0679 0.2511 8.236 3.83e-16 *** income2 2.9242 0.0781 37.442 < 2e-16 *** --- Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 3.495 on 1498 degrees of freedom Multiple R-squared: 0.9136, Adjusted R-squared: 0.9134 F-statistic: 7916 on 2 and 1498 DF, p-value: < 2.2e-16
> summary(lm(savings ~ income + 0))
Response Y1 :
Call: lm(formula = Y1 ~ income + 0)
Residuals: Min 1Q Median 3Q Max -13.28453 -2.07748 -0.02677 1.97241 15.19239
Coefficients: Estimate Std. Error t value Pr(>|t|) income1 -1.0679 0.2511 -4.253 2.24e-05 *** income2 -2.9242 0.0781 -37.442 < 2e-16 *** --- Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 3.495 on 1498 degrees of freedom Multiple R-squared: 0.8987, Adjusted R-squared: 0.8986 F-statistic: 6646 on 2 and 1498 DF, p-value: < 2.2e-16

Response Y2 :

Call: lm(formula = Y2 ~ income + 0)
Residuals: Min 1Q Median 3Q Max -13.28453 -2.07748 -0.02677 1.97241 15.19239
Coefficients: Estimate Std. Error t value Pr(>|t|) income1 -2.0679 0.2511 -8.236 3.83e-16 *** income2 -1.9242 0.0781 -24.638 < 2e-16 *** --- Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
Residual standard error: 3.495 on 1498 degrees of freedom Multiple R-squared: 0.8448, Adjusted R-squared: 0.8446 F-statistic: 4078 on 2 and 1498 DF, p-value: < 2.2e-16

Take away
The percentage of unexplained variance is the same but r square is different. This is mainly becoz there is a large variation in consumption variable whereas there is smaller variation in savings.!! Never trust R square!