Period S&P CPI M2 TD UN CC 2007-02-01 -2.185 0.388 0.228 -0.507 -2.174 -5.779 20
ID: 3176180 • Letter: P
Question
Period S&P CPI M2 TD UN CC 2007-02-01 -2.185 0.388 0.228 -0.507 -2.174 -5.779 2007-03-01 0.998 0.520 0.489 -1.262 -2.222 -3.176 2007-04-01 4.329 0.300 1.006 -0.847 2.273 -1.471 2007-05-01 3.255 0.413 0.200 -0.250 -2.222 1.378 2007-06-01 -1.782 0.232 0.453 -1.282 4.545 -3.398 2007-07-01 -3.198 0.178 0.409 0.560 2.174 5.979 2007-08-01 1.286 0.031 1.042 -1.392 -2.128 -7.743 2007-09-01 3.579 0.424 0.242 -1.974 2.174 0.000 2007-10-01 1.482 0.308 0.180 -1.413 0.000 -2.998 2007-11-01 -4.404 0.786 0.345 0.836 0.000 -5.933 2007-12-01 -0.863 0.290 0.420 -0.836 6.383 -0.788 2008-01-01 -6.116 0.345 0.458 -0.829 0.000 3.841 2008-02-01 -3.476 0.242 1.140 -1.962 -2.000 -9.694 2008-03-01 -0.596 0.358 0.900 -0.387 4.082 -1.836 2008-04-01 4.755 0.231 0.567 0.378 -1.961 -9.928 2008-05-01 1.067 0.592 0.150 0.185 8.000 -4.473 2008-06-01 -8.596 1.048 0.212 -0.734 3.704 -5.686 2008-07-01 -0.986 0.714 0.577 2.637 3.571 8.511 2008-08-01 1.219 -0.149 0.174 2.470 5.172 2.941 2008-09-01 -9.079 0.086 0.881 6.633 0.000 11.587 2008-10-01 -16.942 -0.860 1.378 2.508 6.557 -18.065 2008-11-01 -7.485 -1.771 0.648 -1.047 4.615 -3.993 2008-12-01 0.782 -0.823 2.226 0.623 7.353 8.680 2009-01-01 -8.566 0.253 1.006 2.462 6.849 1.830 2009-02-01 -10.993 0.364 0.372 0.434 6.410 -8.007 2009-03-01 8.540 -0.099 0.823 -2.482 4.819 1.776 2009-04-01 9.393 0.101 0.048 -2.876 3.448 13.613 2009-05-01 5.308 0.147 0.676 -1.281 4.444 5.530 2009-06-01 0.020 0.830 0.086 -0.375 1.064 3.057 2009-07-01 7.414 -0.030 0.018 -1.196 0.000 -6.780 2009-08-01 3.356 0.335 -0.031 -0.754 1.053 -0.455 2009-09-01 3.572 0.193 -0.054 -1.427 2.083 11.872 2009-10-01 -1.976 0.300 0.351 -0.475 2.041 -3.946 2009-11-01 5.736 0.335 0.393 0.446 -1.000 -4.533 2009-12-01 1.777 0.052 -0.024 0.283 0.000 7.567 2010-01-01 -3.697 0.065 -0.425 1.501 -1.010 2.621 2010-02-01 2.851 -0.095 0.611 -0.856 0.000 -1.075 2010-03-01 5.880 0.033 -0.001 -0.498 1.020 0.000 2010-04-01 1.476 0.023 0.379 2.773 0.000 -1.902 2010-05-01 -8.198 -0.052 0.617 0.547 -3.030 1.939 2010-06-01 -5.388 -0.042 0.169 -1.559 -2.083 3.261 2010-07-01 6.878 0.187 0.057 -0.778 0.000 -10.789 2010-08-01 -4.745 0.146 0.545 -0.976 1.064 1.622 2010-09-01 8.755 0.162 0.290 -2.599 0.000 -1.016 2010-10-01 3.686 0.348 0.597 0.286 -1.053 -0.733 2010-11-01 -0.229 0.253 0.314 0.664 4.255 5.761 2010-12-01 6.530 0.402 0.409 -1.156 -5.102 4.050 2011-01-01 2.265 0.324 0.450 -0.763 -2.151 -0.403 2011-02-01 3.196 0.321 0.552 -0.958 -1.099 4.447 2011-03-01 -0.105 0.517 0.540 -1.658 0.000 -12.903 2011-04-01 2.850 0.469 0.729 -0.039 1.111 3.407 2011-05-01 -1.350 0.318 0.547 -0.026 -1.099 6.447 2011-06-01 -1.826 0.000 0.875 -0.685 1.111 -3.769 2011-07-01 -2.147 0.262 1.999 0.572 -1.099 -10.909 2011-08-01 -5.679 0.315 2.240 2.992 0.000 -12.402 2011-09-01 -7.176 0.217 0.186 0.924 0.000 6.631 2011-10-01 10.772 0.068 0.347 0.642 -2.222 2.185 2011-11-01 -0.506 0.185 0.530 0.944 -2.273 4.770 2011-12-01 0.853 0.024 0.452 -0.619 -1.163 9.733 2012-01-01 4.358 0.272 0.855 -1.736 -2.353 7.296 2012-02-01 4.059 0.214 0.474 0.608 0.000 0.400 2012-03-01 3.133 0.209 0.489 0.323 -1.205 1.195 2012-04-01 -0.750 0.166 0.583 1.742 0.000 0.262 2012-05-01 -6.265 -0.207 0.285 1.432 0.000 3.796 2012-06-01 3.955 -0.083 0.648 -0.470 0.000 -7.692 2012-07-01 1.260 0.029 0.673 -0.868 0.000 -1.230 2012-08-01 1.976 0.581 0.664 -1.566 -1.220 2.766 2012-09-01 2.424 0.477 0.742 -0.281 -3.704 5.384 2012-10-01 -1.979 0.270 0.571 0.640 0.000 5.492 2012-11-01 0.285 -0.168 0.722 -0.578 -1.282 0.121 2012-12-01 0.707 -0.012 1.262 -0.087 2.597 -11.850 2013-01-01 5.043 0.169 0.270 0.822 1.266 1.235 2013-02-01 1.106 0.593 -0.003 0.876 -3.750 5.149 2013-03-01 3.599 -0.294 0.705 -0.358 -2.597 1.289 2013-04-01 1.809 -0.217 0.352 0.433 1.333 -2.799 2013-05-01 2.076 0.052 0.319 0.807 -1.316 10.602 2013-06-01 -1.500 0.197 0.475 0.548 0.000 -0.473 2013-07-01 4.946 0.222 0.482 -0.117 -2.667 1.189 2013-08-01 -3.130 0.186 0.508 -0.209 0.000 -3.525 2013-09-01 2.975 0.132 0.436 -1.005 -1.370 -5.603 2013-10-01 4.460 0.037 0.957 0.888 0.000 -5.548 2013-11-01 2.805 0.172 0.215 0.160 -4.167 2.596 2013-12-01 2.356 0.257 0.598 0.952 -2.899 9.854 2014-01-01 -3.558 0.282 0.481 0.243 -1.493 -1.576 2014-02-01 4.312 0.122 0.751 -0.085 1.515 0.493 2014-03-01 0.693 0.130 0.395 -0.379 0.000 -1.961 2014-04-01 0.620 0.209 0.506 -0.317 -7.463 5.125 2014-05-01 2.103 0.153 0.599 0.148 1.613 -2.616 2014-06-01 1.906 0.083 0.436 -0.236 -3.175 0.733 2014-07-01 -1.508 0.167 0.529 0.899 1.639 -0.848 2014-08-01 3.766 -0.071 0.243 1.509 0.000 0.856 2014-09-01 -1.551 0.097 0.275 1.290 -4.839 2.545 2014-10-01 2.320 0.008 0.392 1.696 -3.390 2.719 2014-11-01 2.453 -0.163 0.485 2.450 1.754 2.186 2014-12-01 -0.419 -0.349 0.697 2.130 -3.448 5.405 2015-01-01 -3.104 -0.583 0.563 1.279 1.786 4.808 2015-02-01 5.489 0.245 1.005 1.810 -3.509 -2.752 2015-03-01 -1.740 0.212 0.185 -0.979 -1.818 -2.516 2015-04-01 0.852 0.090 0.380 -0.769 0.000 3.118 2015-05-01 1.049 0.292 0.291 0.772 1.852 -5.422 2015-06-01 -2.101 0.223 0.374 1.731 -3.636 5.954 2015-07-01 1.974 0.192 0.447 1.866 -1.887 -3.122 2015-08-01 -6.258 -0.027 0.424 0.761 -1.923 -1.289 2015-09-01 -2.644 -0.145 0.439 -0.872 -1.961 -5.114 2015-10-01 8.298 0.137 0.109 1.522 0.000 3.211 2015-11-01 0.050 0.152 0.841 1.015 0.000 1.444 2015-12-01 -1.753 -0.129 0.491 2.247 0.000 1.424 2016-01-01 -5.074 0.109 1.057 -0.866 -2.000 -0.648 2016-02-01 -0.413 -0.125 0.550 -2.010 0.000 -0.326 2016-03-01 6.599 0.114 0.575 -1.593 2.041 -0.763 2016-04-01 0.270 0.349 0.682 1.054 0.000 -2.198 2016-05-01 1.532 0.190 0.583 0.368 -6.000 6.404 2016-06-01 0.091 0.201 0.542 0.692 4.255 -1.267 2016-07-01 3.561 0.023 0.477 -0.918 0.000 -3.743 2016-08-01 -0.122 0.205 0.646 0.768 0.000 -0.222 2016-09-01 -0.123 0.257 0.465 0.930 0.000 1.559 2016-10-01 -1.943 0.285 0.423 2.356 -2.041 -4.386 2016-11-01 3.417 0.209 0.591 1.539 -4.167 7.569 2016-12-01 1.820 0.257 0.283 -0.096 2.174 4.691 2017-01-01 1.788 0.551 0.630 -1.410 2.128 0.305 Following are the definitions of the variable names in the attached data set. Definitions variables: Period = Month S&P; = S&P; 500 Index CPI = Consumer Price Index M2 = Money Supply M2 TD = Trade Weighted Dollar Index UN = Unemployment Rate CC = Consumer Confidence Index Please use the attached data set and Excel to estimate the following 2 regression models: Model 1: S & P = beta_0 + beta_1 CC + epsilon Model 2 S & P = beta_0 + beta_1 CPI + beta_2 M2 + beta_3 TD + beta_4 UN + beta_5 CC + epsilon Use the t-statistics and the 5 percent significant level to test if any of the independent variables in model 2 is significant (please carefully explain your testing steps as 1 described in the video lecture)? Re-estimate the model 2 excluding the variables(s) that is/are determined to be insignificant in (ii).Explanation / Answer
First, we can load the data into R environment with below command:
InputData <- read.table("data.txt",sep = " ", header = T)
Model 1 can be fitted as below:
#Fit model 1
Model1 <- lm(SP~CC,data=InputData)
summary(Model1)
Call:
lm(formula = SP ~ CC, data = InputData)
Residuals:
Min 1Q Median 3Q Max
-14.8129 -1.8748 0.2866 2.5594 10.0003
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 0.45872 0.39822 1.152 0.2517
CC 0.14325 0.07225 1.983 0.0497 *
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Residual standard error: 4.36 on 118 degrees of freedom
Multiple R-squared: 0.03224, Adjusted R-squared: 0.02404
F-statistic: 3.931 on 1 and 118 DF, p-value: 0.04974
#Fit model 2
Model2 <- lm(SP~CPI+M2+TD+UN+CC,data=InputData)
summary(Model2)
Call:
lm(formula = SP ~ CPI + M2 + TD + UN + CC, data = InputData)
Residuals:
Min 1Q Median 3Q Max
-9.3653 -2.3756 0.1344 2.4933 9.9032
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 1.00286 0.71087 1.411 0.161043
CPI 0.80287 1.19649 0.671 0.503565
M2 -0.93592 1.03534 -0.904 0.367917
TD -1.09442 0.27259 -4.015 0.000107 ***
UN -0.24195 0.13368 -1.810 0.072943 .
CC 0.13782 0.07077 1.948 0.053930 .
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Residual standard error: 4.026 on 114 degrees of freedom
Multiple R-squared: 0.203, Adjusted R-squared: 0.168
F-statistic: 5.806 on 5 and 114 DF, p-value: 8.177e-05
Answer (i) In model 2, at 5% significance level, TD and CC(approximately) variables are significant, as their p-values are 0.05 or less.
Answer (ii) Now, we'll exclude all the variables which were insignificant in part i. So we'll refit the model with only 2 independent variables TD and CC.
#Fit updated model 2 with only significant predictors
Model2_Updated <- lm(SP~TD+CC,data=InputData)
summary(Model2_Updated)
Call:
lm(formula = SP ~ TD + CC, data = InputData)
Residuals:
Min 1Q Median 3Q Max
-11.4691 -2.3239 0.2368 2.3903 10.5118
Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 0.6175 0.3736 1.653 0.1011
TD -1.1572 0.2700 -4.287 3.75e-05 ***
CC 0.1765 0.0679 2.599 0.0105 *
---
Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
Residual standard error: 4.071 on 117 degrees of freedom
Multiple R-squared: 0.1636, Adjusted R-squared: 0.1493
F-statistic: 11.44 on 2 and 117 DF, p-value: 2.893e-05