Introduction

This Homework is on better understanding of how to build a linear model and check the assumptions of that model. Data for this assignment can be found at: http://asayanalytics.com/bikeshare_csv. The code and analysis are property of Clifford Gammon.

Question 1

## 
## Call:
## lm(formula = total.rider ~ poly(temp, 3, raw = TRUE) + as.factor(Promotion) + 
##     poly(windspeed, 3, raw = T) + poly(humidity, 2, raw = T) + 
##     as.factor(weathersit) + as.factor(mnth), data = bike_share)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -3301.3  -355.1    58.5   431.3  2269.5 
## 
## Coefficients:
##                                Estimate Std. Error t value Pr(>|t|)    
## (Intercept)                   2.035e+03  6.668e+02   3.052 0.002360 ** 
## poly(temp, 3, raw = TRUE)1   -2.911e+02  8.182e+01  -3.557 0.000400 ***
## poly(temp, 3, raw = TRUE)2    3.321e+01  4.440e+00   7.480 2.21e-13 ***
## poly(temp, 3, raw = TRUE)3   -7.041e-01  7.416e-02  -9.494  < 2e-16 ***
## as.factor(Promotion)1         1.945e+03  5.528e+01  35.186  < 2e-16 ***
## poly(windspeed, 3, raw = T)1 -1.057e+02  6.173e+01  -1.713 0.087230 .  
## poly(windspeed, 3, raw = T)2  5.571e+00  4.264e+00   1.306 0.191869    
## poly(windspeed, 3, raw = T)3 -1.544e-01  9.000e-02  -1.716 0.086690 .  
## poly(humidity, 2, raw = T)1   3.736e+01  1.398e+01   2.673 0.007689 ** 
## poly(humidity, 2, raw = T)2  -4.974e-01  1.146e-01  -4.338 1.64e-05 ***
## as.factor(weathersit)2       -3.310e+02  7.370e+01  -4.491 8.28e-06 ***
## as.factor(weathersit)3       -1.414e+03  2.083e+02  -6.791 2.36e-11 ***
## as.factor(mnth)2              4.744e+01  1.405e+02   0.338 0.735760    
## as.factor(mnth)3              5.145e+02  1.528e+02   3.367 0.000802 ***
## as.factor(mnth)4              6.475e+02  1.701e+02   3.808 0.000153 ***
## as.factor(mnth)5              8.068e+02  1.915e+02   4.214 2.84e-05 ***
## as.factor(mnth)6              9.282e+02  2.160e+02   4.298 1.97e-05 ***
## as.factor(mnth)7              1.149e+03  2.381e+02   4.823 1.73e-06 ***
## as.factor(mnth)8              9.351e+02  2.207e+02   4.237 2.57e-05 ***
## as.factor(mnth)9              1.251e+03  1.974e+02   6.338 4.15e-10 ***
## as.factor(mnth)10             1.323e+03  1.710e+02   7.733 3.62e-14 ***
## as.factor(mnth)11             1.076e+03  1.551e+02   6.942 8.77e-12 ***
## as.factor(mnth)12             7.853e+02  1.453e+02   5.406 8.82e-08 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 722.8 on 708 degrees of freedom
## Multiple R-squared:  0.865,  Adjusted R-squared:  0.8608 
## F-statistic: 206.1 on 22 and 708 DF,  p-value: < 2.2e-16
##                      bike_share$humidity bike_share$weathersit
## bike_share$temp                0.1269629           -0.12060224
## bike_share$Promotion          -0.1106510           -0.04872654
## bike_share$windspeed          -0.2484891            0.03951106
##                      bike_share$mnth
## bike_share$temp          0.220205335
## bike_share$Promotion    -0.001792434
## bike_share$windspeed    -0.207501752

Based on the output above we can see that over 86% of the variation in our total rider population can be explained by our model. And that none of our variables are very highly correlated

Question 2

Based on the above Studentized residual QQPlot we can see that there is some curvature to our residuals. This would indicate that our assumptions of normally distributed residuals is in danger of being violated

From our crPlots we can see that the indepentant variables have been raised to the right power and that they have a fairly linear relationship. The only indepentant variable that might be some cause for concern in windspeed as it still does have some curvature to it. This is most likely caused by the potential outlier to the far left of the graph.

##                                  GVIF Df GVIF^(1/(2*Df))
## poly(temp, 3, raw = TRUE)   20.992285  3        1.660899
## as.factor(Promotion)         1.068785  1        1.033820
## poly(windspeed, 3, raw = T)  1.380579  3        1.055221
## poly(humidity, 2, raw = T)   3.113551  2        1.328354
## as.factor(weathersit)        2.375788  2        1.241515
## as.factor(mnth)             24.303959 11        1.156073

From our VIF output we can see that most of the variables are not multicollinearity. However, month has a very high collinear VIF score of over 24, this is most likely because our other variable Temp is better able to explain our total bike rider.

Question 3

If we were to keep everything else constant, we would expect that the month of October to have the highest number of riders than any other month. For that month alone, we would expect an additional 1323 riders just due to the month alone. However, let us take a look at how this would change if we were to have an unseasonably cold October

## 
## Call:
## lm(formula = total.rider ~ poly(temp, 3, raw = TRUE) + as.factor(Promotion) + 
##     poly(windspeed, 3, raw = T) + poly(humidity, 2, raw = T) + 
##     as.factor(weathersit) + as.factor(mnth) + (as.factor(mnth) + 
##     as.factor(weathersit) + poly(temp, 3, raw = TRUE))^3, data = bike_share)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -3341.6  -307.5    21.9   365.8  1822.0 
## 
## Coefficients: (28 not defined because of singularities)
##                                                                       Estimate
## (Intercept)                                                          1.364e+03
## poly(temp, 3, raw = TRUE)1                                          -6.666e+01
## poly(temp, 3, raw = TRUE)2                                           1.044e+01
## poly(temp, 3, raw = TRUE)3                                          -1.108e-01
## as.factor(Promotion)1                                                1.993e+03
## poly(windspeed, 3, raw = T)1                                        -7.897e+01
## poly(windspeed, 3, raw = T)2                                         3.726e+00
## poly(windspeed, 3, raw = T)3                                        -1.095e-01
## poly(humidity, 2, raw = T)1                                          3.146e+01
## poly(humidity, 2, raw = T)2                                         -4.496e-01
## as.factor(weathersit)2                                              -3.821e+03
## as.factor(weathersit)3                                               6.862e+05
## as.factor(mnth)2                                                     3.114e+02
## as.factor(mnth)3                                                     2.374e+03
## as.factor(mnth)4                                                    -1.701e+04
## as.factor(mnth)5                                                     3.625e+04
## as.factor(mnth)6                                                    -3.345e+04
## as.factor(mnth)7                                                     6.769e+04
## as.factor(mnth)8                                                    -4.652e+05
## as.factor(mnth)9                                                    -1.974e+05
## as.factor(mnth)10                                                   -2.512e+04
## as.factor(mnth)11                                                   -2.779e+04
## as.factor(mnth)12                                                   -2.277e+04
## as.factor(weathersit)2:as.factor(mnth)2                             -1.367e+03
## as.factor(weathersit)3:as.factor(mnth)2                              4.519e+03
## as.factor(weathersit)2:as.factor(mnth)3                              5.797e+02
## as.factor(weathersit)3:as.factor(mnth)3                              5.347e+04
## as.factor(weathersit)2:as.factor(mnth)4                              9.472e+03
## as.factor(weathersit)3:as.factor(mnth)4                              4.651e+04
## as.factor(weathersit)2:as.factor(mnth)5                             -2.156e+05
## as.factor(weathersit)3:as.factor(mnth)5                                     NA
## as.factor(weathersit)2:as.factor(mnth)6                              3.226e+05
## as.factor(weathersit)3:as.factor(mnth)6                                     NA
## as.factor(weathersit)2:as.factor(mnth)7                              1.531e+06
## as.factor(weathersit)3:as.factor(mnth)7                              1.445e+05
## as.factor(weathersit)2:as.factor(mnth)8                              1.617e+05
## as.factor(weathersit)3:as.factor(mnth)8                                     NA
## as.factor(weathersit)2:as.factor(mnth)9                              2.333e+05
## as.factor(weathersit)3:as.factor(mnth)9                              2.596e+06
## as.factor(weathersit)2:as.factor(mnth)10                             7.966e+03
## as.factor(weathersit)3:as.factor(mnth)10                            -5.490e+05
## as.factor(weathersit)2:as.factor(mnth)11                             1.502e+04
## as.factor(weathersit)3:as.factor(mnth)11                             2.163e+04
## as.factor(weathersit)2:as.factor(mnth)12                             1.732e+04
## as.factor(weathersit)3:as.factor(mnth)12                             1.548e+04
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)2                         -1.150e+02
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)2                          1.640e+01
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)2                         -5.770e-01
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)3                         -4.455e+02
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)3                          3.252e+01
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)3                         -7.109e-01
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)4                          2.615e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)4                         -1.191e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)4                          1.699e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)5                         -4.514e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)5                          1.988e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)5                         -2.987e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)6                          3.460e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)6                         -1.035e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)6                          8.177e-01
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)7                         -6.357e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)7                          2.137e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)7                         -2.583e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)8                          4.824e+04
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)8                         -1.653e+03
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)8                          1.869e+01
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)9                          2.355e+04
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)9                         -9.136e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)9                          1.160e+01
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)10                         4.266e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)10                        -2.157e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)10                         3.522e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)11                         5.379e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)11                        -3.238e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)11                         6.372e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)12                         5.161e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)12                        -3.666e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)12                         8.578e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2                    1.017e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2                   -8.484e+01
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2                    2.254e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3                   -1.497e+05
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3                    1.014e+04
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3                   -2.215e+02
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)2   9.499e+02
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)2  -1.245e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)2   4.292e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)2          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)2          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)2          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)3  -2.678e+02
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)3   2.899e+01
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)3  -8.820e-01
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)3  -2.193e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)3          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)3          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)4  -1.551e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)4   8.879e+01
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)4  -1.914e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)4  -1.901e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)4          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)4          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)5   2.911e+04
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)5  -1.279e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)5   1.806e+01
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)5          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)5          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)5          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)6  -3.582e+04
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)6   1.333e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)6  -1.698e+01
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)6          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)6          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)6          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)7  -1.547e+05
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)7   5.217e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)7  -5.914e+01
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)7          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)7          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)7          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)8  -1.694e+04
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)8   6.038e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)8  -7.707e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)8          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)8          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)8          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)9  -2.837e+04
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)9   1.161e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)9  -1.628e+01
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)9  -2.521e+05
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)9   6.212e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)9          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)10 -2.200e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)10  1.632e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)10 -3.807e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)10  1.250e+05
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)10 -8.777e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)10  1.973e+02
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)11 -3.100e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)11  2.146e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)11 -4.964e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)11 -4.014e+02
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)11         NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)11         NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)12 -5.151e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)12  4.457e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)12 -1.188e+01
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)12         NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)12         NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)12         NA
##                                                                     Std. Error
## (Intercept)                                                          1.536e+03
## poly(temp, 3, raw = TRUE)1                                           5.214e+02
## poly(temp, 3, raw = TRUE)2                                           5.917e+01
## poly(temp, 3, raw = TRUE)3                                           2.081e+00
## as.factor(Promotion)1                                                5.773e+01
## poly(windspeed, 3, raw = T)1                                         6.280e+01
## poly(windspeed, 3, raw = T)2                                         4.336e+00
## poly(windspeed, 3, raw = T)3                                         9.133e-02
## poly(humidity, 2, raw = T)1                                          1.675e+01
## poly(humidity, 2, raw = T)2                                          1.342e-01
## as.factor(weathersit)2                                               3.659e+03
## as.factor(weathersit)3                                               6.666e+05
## as.factor(mnth)2                                                     3.128e+03
## as.factor(mnth)3                                                     6.106e+03
## as.factor(mnth)4                                                     2.378e+04
## as.factor(mnth)5                                                     4.146e+04
## as.factor(mnth)6                                                     8.528e+04
## as.factor(mnth)7                                                     3.019e+05
## as.factor(mnth)8                                                     5.394e+05
## as.factor(mnth)9                                                     1.159e+05
## as.factor(mnth)10                                                    2.353e+04
## as.factor(mnth)11                                                    1.466e+04
## as.factor(mnth)12                                                    1.511e+04
## as.factor(weathersit)2:as.factor(mnth)2                              7.825e+03
## as.factor(weathersit)3:as.factor(mnth)2                              5.577e+03
## as.factor(weathersit)2:as.factor(mnth)3                              1.276e+04
## as.factor(weathersit)3:as.factor(mnth)3                              4.368e+04
## as.factor(weathersit)2:as.factor(mnth)4                              3.190e+04
## as.factor(weathersit)3:as.factor(mnth)4                              6.626e+04
## as.factor(weathersit)2:as.factor(mnth)5                              8.587e+04
## as.factor(weathersit)3:as.factor(mnth)5                                     NA
## as.factor(weathersit)2:as.factor(mnth)6                              1.538e+05
## as.factor(weathersit)3:as.factor(mnth)6                                     NA
## as.factor(weathersit)2:as.factor(mnth)7                              2.304e+06
## as.factor(weathersit)3:as.factor(mnth)7                              1.475e+05
## as.factor(weathersit)2:as.factor(mnth)8                              1.186e+06
## as.factor(weathersit)3:as.factor(mnth)8                                     NA
## as.factor(weathersit)2:as.factor(mnth)9                              1.344e+05
## as.factor(weathersit)3:as.factor(mnth)9                              2.379e+06
## as.factor(weathersit)2:as.factor(mnth)10                             2.933e+04
## as.factor(weathersit)3:as.factor(mnth)10                             6.679e+05
## as.factor(weathersit)2:as.factor(mnth)11                             3.673e+04
## as.factor(weathersit)3:as.factor(mnth)11                             2.527e+04
## as.factor(weathersit)2:as.factor(mnth)12                             2.501e+04
## as.factor(weathersit)3:as.factor(mnth)12                             1.814e+04
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)2                          8.801e+02
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)2                          8.194e+01
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)2                          2.520e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)3                          1.291e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)3                          9.596e+01
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)3                          2.598e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)4                          3.590e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)4                          1.846e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)4                          3.512e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)5                          5.033e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)5                          2.085e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)5                          3.364e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)6                          9.070e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)6                          3.244e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)6                          4.268e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)7                          2.908e+04
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)7                          9.332e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)7                          1.014e+01
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)8                          5.571e+04
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)8                          1.914e+03
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)8                          2.195e+01
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)9                          1.381e+04
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)9                          5.475e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)9                          7.413e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)10                         3.850e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)10                         2.113e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)10                         4.106e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)11                         2.929e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)11                         1.950e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)11                         4.427e+00
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)12                         3.414e+03
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)12                         2.539e+02
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)12                         6.233e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2                    1.144e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2                    1.151e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2                    3.684e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3                    1.454e+05
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3                    9.845e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3                    2.151e+02
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)2   2.298e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)2   2.152e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)2   6.428e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)2          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)2          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)2          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)3   2.565e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)3   1.807e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)3   4.585e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)3   1.412e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)3          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)3          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)4   5.130e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)4   2.834e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)4   5.732e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)4   2.856e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)4          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)4          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)5   1.158e+04
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)5   5.260e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)5   8.425e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)5          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)5          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)5          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)6   1.683e+04
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)6   6.175e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)6   8.138e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)6          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)6          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)6          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)7   2.310e+05
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)7   7.699e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)7   8.530e+01
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)7          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)7          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)7          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)8   1.243e+05
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)8   4.334e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)8   5.039e+01
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)8          NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)8          NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)8          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)9   1.614e+04
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)9   6.486e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)9   9.154e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)9   2.331e+05
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)9   5.801e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)9          NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)10  4.786e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)10  2.685e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)10  5.549e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)10  1.456e+05
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)10  9.855e+03
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)10  2.153e+02
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)11  6.960e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)11  4.383e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)11  9.300e+00
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)11  7.731e+02
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)11         NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)11         NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)12  5.776e+03
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)12  4.379e+02
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)12  1.093e+01
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)12         NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)12         NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)12         NA
##                                                                     t value
## (Intercept)                                                           0.888
## poly(temp, 3, raw = TRUE)1                                           -0.128
## poly(temp, 3, raw = TRUE)2                                            0.177
## poly(temp, 3, raw = TRUE)3                                           -0.053
## as.factor(Promotion)1                                                34.519
## poly(windspeed, 3, raw = T)1                                         -1.257
## poly(windspeed, 3, raw = T)2                                          0.859
## poly(windspeed, 3, raw = T)3                                         -1.199
## poly(humidity, 2, raw = T)1                                           1.879
## poly(humidity, 2, raw = T)2                                          -3.350
## as.factor(weathersit)2                                               -1.044
## as.factor(weathersit)3                                                1.029
## as.factor(mnth)2                                                      0.100
## as.factor(mnth)3                                                      0.389
## as.factor(mnth)4                                                     -0.715
## as.factor(mnth)5                                                      0.874
## as.factor(mnth)6                                                     -0.392
## as.factor(mnth)7                                                      0.224
## as.factor(mnth)8                                                     -0.862
## as.factor(mnth)9                                                     -1.703
## as.factor(mnth)10                                                    -1.067
## as.factor(mnth)11                                                    -1.896
## as.factor(mnth)12                                                    -1.507
## as.factor(weathersit)2:as.factor(mnth)2                              -0.175
## as.factor(weathersit)3:as.factor(mnth)2                               0.810
## as.factor(weathersit)2:as.factor(mnth)3                               0.045
## as.factor(weathersit)3:as.factor(mnth)3                               1.224
## as.factor(weathersit)2:as.factor(mnth)4                               0.297
## as.factor(weathersit)3:as.factor(mnth)4                               0.702
## as.factor(weathersit)2:as.factor(mnth)5                              -2.510
## as.factor(weathersit)3:as.factor(mnth)5                                  NA
## as.factor(weathersit)2:as.factor(mnth)6                               2.097
## as.factor(weathersit)3:as.factor(mnth)6                                  NA
## as.factor(weathersit)2:as.factor(mnth)7                               0.665
## as.factor(weathersit)3:as.factor(mnth)7                               0.979
## as.factor(weathersit)2:as.factor(mnth)8                               0.136
## as.factor(weathersit)3:as.factor(mnth)8                                  NA
## as.factor(weathersit)2:as.factor(mnth)9                               1.736
## as.factor(weathersit)3:as.factor(mnth)9                               1.091
## as.factor(weathersit)2:as.factor(mnth)10                              0.272
## as.factor(weathersit)3:as.factor(mnth)10                             -0.822
## as.factor(weathersit)2:as.factor(mnth)11                              0.409
## as.factor(weathersit)3:as.factor(mnth)11                              0.856
## as.factor(weathersit)2:as.factor(mnth)12                              0.693
## as.factor(weathersit)3:as.factor(mnth)12                              0.853
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)2                          -0.131
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)2                           0.200
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)2                          -0.229
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)3                          -0.345
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)3                           0.339
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)3                          -0.274
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)4                           0.728
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)4                          -0.645
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)4                           0.484
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)5                          -0.897
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)5                           0.953
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)5                          -0.888
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)6                           0.381
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)6                          -0.319
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)6                           0.192
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)7                          -0.219
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)7                           0.229
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)7                          -0.255
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)8                           0.866
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)8                          -0.863
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)8                           0.851
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)9                           1.706
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)9                          -1.669
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)9                           1.564
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)10                          1.108
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)10                         -1.021
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)10                          0.858
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)11                          1.837
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)11                         -1.660
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)11                          1.440
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)12                          1.512
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)12                         -1.444
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)12                          1.376
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2                     0.889
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2                    -0.737
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2                     0.612
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3                    -1.030
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3                     1.030
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3                    -1.030
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)2    0.413
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)2   -0.579
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)2    0.668
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)2       NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)2       NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)2       NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)3   -0.104
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)3    0.160
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)3   -0.192
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)3   -1.553
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)3       NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)3       NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)4   -0.302
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)4    0.313
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)4   -0.334
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)4   -0.666
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)4       NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)4       NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)5    2.513
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)5   -2.431
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)5    2.144
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)5       NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)5       NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)5       NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)6   -2.129
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)6    2.158
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)6   -2.086
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)6       NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)6       NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)6       NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)7   -0.670
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)7    0.678
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)7   -0.693
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)7       NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)7       NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)7       NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)8   -0.136
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)8    0.139
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)8   -0.153
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)8       NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)8       NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)8       NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)9   -1.758
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)9    1.790
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)9   -1.778
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)9   -1.082
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)9    1.071
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)9       NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)10  -0.460
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)10   0.608
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)10  -0.686
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)10   0.859
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)10  -0.891
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)10   0.917
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)11  -0.445
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)11   0.490
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)11  -0.534
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)11  -0.519
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)11      NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)11      NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)12  -0.892
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)12   1.018
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)12  -1.087
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)12      NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)12      NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)12      NA
##                                                                     Pr(>|t|)
## (Intercept)                                                         0.374825
## poly(temp, 3, raw = TRUE)1                                          0.898317
## poly(temp, 3, raw = TRUE)2                                          0.859942
## poly(temp, 3, raw = TRUE)3                                          0.957545
## as.factor(Promotion)1                                                < 2e-16
## poly(windspeed, 3, raw = T)1                                        0.209070
## poly(windspeed, 3, raw = T)2                                        0.390535
## poly(windspeed, 3, raw = T)3                                        0.231187
## poly(humidity, 2, raw = T)1                                         0.060776
## poly(humidity, 2, raw = T)2                                         0.000857
## as.factor(weathersit)2                                              0.296728
## as.factor(weathersit)3                                              0.303709
## as.factor(mnth)2                                                    0.920726
## as.factor(mnth)3                                                    0.697594
## as.factor(mnth)4                                                    0.474797
## as.factor(mnth)5                                                    0.382313
## as.factor(mnth)6                                                    0.695046
## as.factor(mnth)7                                                    0.822675
## as.factor(mnth)8                                                    0.388756
## as.factor(mnth)9                                                    0.089081
## as.factor(mnth)10                                                   0.286267
## as.factor(mnth)11                                                   0.058459
## as.factor(mnth)12                                                   0.132261
## as.factor(weathersit)2:as.factor(mnth)2                             0.861431
## as.factor(weathersit)3:as.factor(mnth)2                             0.418075
## as.factor(weathersit)2:as.factor(mnth)3                             0.963766
## as.factor(weathersit)3:as.factor(mnth)3                             0.221419
## as.factor(weathersit)2:as.factor(mnth)4                             0.766636
## as.factor(weathersit)3:as.factor(mnth)4                             0.482986
## as.factor(weathersit)2:as.factor(mnth)5                             0.012323
## as.factor(weathersit)3:as.factor(mnth)5                                   NA
## as.factor(weathersit)2:as.factor(mnth)6                             0.036400
## as.factor(weathersit)3:as.factor(mnth)6                                   NA
## as.factor(weathersit)2:as.factor(mnth)7                             0.506473
## as.factor(weathersit)3:as.factor(mnth)7                             0.327738
## as.factor(weathersit)2:as.factor(mnth)8                             0.891603
## as.factor(weathersit)3:as.factor(mnth)8                                   NA
## as.factor(weathersit)2:as.factor(mnth)9                             0.083081
## as.factor(weathersit)3:as.factor(mnth)9                             0.275607
## as.factor(weathersit)2:as.factor(mnth)10                            0.786014
## as.factor(weathersit)3:as.factor(mnth)10                            0.411412
## as.factor(weathersit)2:as.factor(mnth)11                            0.682709
## as.factor(weathersit)3:as.factor(mnth)11                            0.392242
## as.factor(weathersit)2:as.factor(mnth)12                            0.488818
## as.factor(weathersit)3:as.factor(mnth)12                            0.393808
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)2                         0.896071
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)2                         0.841440
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)2                         0.819008
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)3                         0.730117
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)3                         0.734820
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)3                         0.784453
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)4                         0.466711
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)4                         0.519234
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)4                         0.628808
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)5                         0.370051
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)5                         0.340869
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)5                         0.374999
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)6                         0.703006
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)6                         0.749878
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)6                         0.848110
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)7                         0.827037
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)7                         0.818941
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)7                         0.798986
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)8                         0.386880
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)8                         0.388358
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)8                         0.394915
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)9                         0.088594
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)9                         0.095696
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)9                         0.118265
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)10                        0.268270
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)10                        0.307716
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)10                        0.391392
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)11                        0.066739
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)11                        0.097438
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)11                        0.150516
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)12                        0.131115
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)12                        0.149317
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)12                        0.169232
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2                   0.374291
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2                   0.461376
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2                   0.540886
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3                   0.303652
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3                   0.303261
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3                   0.303604
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)2  0.679532
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)2  0.563040
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)2  0.504584
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)2        NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)2        NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)2        NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)3  0.916895
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)3  0.872582
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)3  0.847521
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)3  0.120863
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)3        NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)3        NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)4  0.762470
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)4  0.754173
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)4  0.738547
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)4  0.505926
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)4        NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)4        NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)5  0.012226
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)5  0.015351
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)5  0.032416
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)5        NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)5        NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)5        NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)6  0.033664
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)6  0.031286
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)6  0.037383
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)6        NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)6        NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)6        NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)7  0.503340
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)7  0.498232
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)7  0.488319
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)7        NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)7        NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)7        NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)8  0.891621
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)8  0.889245
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)8  0.878508
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)8        NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)8        NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)8        NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)9  0.079326
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)9  0.074022
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)9  0.075911
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)9  0.279808
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)9  0.284666
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)9        NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)10 0.645969
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)10 0.543420
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)10 0.492905
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)10 0.390915
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)10 0.373503
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)10 0.359720
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)11 0.656241
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)11 0.624543
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)11 0.593701
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)11 0.603835
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)11       NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)11       NA
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)12 0.372800
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)12 0.309140
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)12 0.277463
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)12       NA
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)12       NA
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)12       NA
##                                                                        
## (Intercept)                                                            
## poly(temp, 3, raw = TRUE)1                                             
## poly(temp, 3, raw = TRUE)2                                             
## poly(temp, 3, raw = TRUE)3                                             
## as.factor(Promotion)1                                               ***
## poly(windspeed, 3, raw = T)1                                           
## poly(windspeed, 3, raw = T)2                                           
## poly(windspeed, 3, raw = T)3                                           
## poly(humidity, 2, raw = T)1                                         .  
## poly(humidity, 2, raw = T)2                                         ***
## as.factor(weathersit)2                                                 
## as.factor(weathersit)3                                                 
## as.factor(mnth)2                                                       
## as.factor(mnth)3                                                       
## as.factor(mnth)4                                                       
## as.factor(mnth)5                                                       
## as.factor(mnth)6                                                       
## as.factor(mnth)7                                                       
## as.factor(mnth)8                                                       
## as.factor(mnth)9                                                    .  
## as.factor(mnth)10                                                      
## as.factor(mnth)11                                                   .  
## as.factor(mnth)12                                                      
## as.factor(weathersit)2:as.factor(mnth)2                                
## as.factor(weathersit)3:as.factor(mnth)2                                
## as.factor(weathersit)2:as.factor(mnth)3                                
## as.factor(weathersit)3:as.factor(mnth)3                                
## as.factor(weathersit)2:as.factor(mnth)4                                
## as.factor(weathersit)3:as.factor(mnth)4                                
## as.factor(weathersit)2:as.factor(mnth)5                             *  
## as.factor(weathersit)3:as.factor(mnth)5                                
## as.factor(weathersit)2:as.factor(mnth)6                             *  
## as.factor(weathersit)3:as.factor(mnth)6                                
## as.factor(weathersit)2:as.factor(mnth)7                                
## as.factor(weathersit)3:as.factor(mnth)7                                
## as.factor(weathersit)2:as.factor(mnth)8                                
## as.factor(weathersit)3:as.factor(mnth)8                                
## as.factor(weathersit)2:as.factor(mnth)9                             .  
## as.factor(weathersit)3:as.factor(mnth)9                                
## as.factor(weathersit)2:as.factor(mnth)10                               
## as.factor(weathersit)3:as.factor(mnth)10                               
## as.factor(weathersit)2:as.factor(mnth)11                               
## as.factor(weathersit)3:as.factor(mnth)11                               
## as.factor(weathersit)2:as.factor(mnth)12                               
## as.factor(weathersit)3:as.factor(mnth)12                               
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)2                            
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)2                            
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)2                            
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)3                            
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)3                            
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)3                            
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)4                            
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)4                            
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)4                            
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)5                            
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)5                            
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)5                            
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)6                            
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)6                            
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)6                            
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)7                            
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)7                            
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)7                            
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)8                            
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)8                            
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)8                            
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)9                         .  
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)9                         .  
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)9                            
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)10                           
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)10                           
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)10                           
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)11                        .  
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)11                        .  
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)11                           
## poly(temp, 3, raw = TRUE)1:as.factor(mnth)12                           
## poly(temp, 3, raw = TRUE)2:as.factor(mnth)12                           
## poly(temp, 3, raw = TRUE)3:as.factor(mnth)12                           
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2                      
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2                      
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2                      
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3                      
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3                      
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3                      
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)2     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)2     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)2     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)2     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)2     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)2     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)3     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)3     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)3     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)3     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)3     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)3     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)4     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)4     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)4     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)4     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)4     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)4     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)5  *  
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)5  *  
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)5  *  
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)5     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)5     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)5     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)6  *  
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)6  *  
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)6  *  
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)6     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)6     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)6     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)7     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)7     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)7     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)7     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)7     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)7     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)8     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)8     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)8     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)8     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)8     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)8     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)9  .  
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)9  .  
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)9  .  
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)9     
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)9     
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)9     
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)10    
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)10    
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)10    
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)10    
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)10    
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)10    
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)11    
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)11    
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)11    
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)11    
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)11    
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)11    
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)2:as.factor(mnth)12    
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)2:as.factor(mnth)12    
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)2:as.factor(mnth)12    
## poly(temp, 3, raw = TRUE)1:as.factor(weathersit)3:as.factor(mnth)12    
## poly(temp, 3, raw = TRUE)2:as.factor(weathersit)3:as.factor(mnth)12    
## poly(temp, 3, raw = TRUE)3:as.factor(weathersit)3:as.factor(mnth)12    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 668.7 on 609 degrees of freedom
## Multiple R-squared:  0.9006, Adjusted R-squared:  0.8808 
## F-statistic:  45.6 on 121 and 609 DF,  p-value: < 2.2e-16

While the above output can be hard to read, suffice it to say that if the weather got colder in October the number of riders in October would take drastic decrease (as much as 2200 riders). However, this model does explain over 88% of the variation in total riders.

Question 4

To understand how our promotion play an impact in total riders let us once remind ourselves of the original model:

## 
## Call:
## lm(formula = total.rider ~ poly(temp, 3, raw = TRUE) + as.factor(Promotion) + 
##     poly(windspeed, 3, raw = T) + poly(humidity, 2, raw = T) + 
##     as.factor(weathersit) + as.factor(mnth), data = bike_share)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -3301.3  -355.1    58.5   431.3  2269.5 
## 
## Coefficients:
##                                Estimate Std. Error t value Pr(>|t|)    
## (Intercept)                   2.035e+03  6.668e+02   3.052 0.002360 ** 
## poly(temp, 3, raw = TRUE)1   -2.911e+02  8.182e+01  -3.557 0.000400 ***
## poly(temp, 3, raw = TRUE)2    3.321e+01  4.440e+00   7.480 2.21e-13 ***
## poly(temp, 3, raw = TRUE)3   -7.041e-01  7.416e-02  -9.494  < 2e-16 ***
## as.factor(Promotion)1         1.945e+03  5.528e+01  35.186  < 2e-16 ***
## poly(windspeed, 3, raw = T)1 -1.057e+02  6.173e+01  -1.713 0.087230 .  
## poly(windspeed, 3, raw = T)2  5.571e+00  4.264e+00   1.306 0.191869    
## poly(windspeed, 3, raw = T)3 -1.544e-01  9.000e-02  -1.716 0.086690 .  
## poly(humidity, 2, raw = T)1   3.736e+01  1.398e+01   2.673 0.007689 ** 
## poly(humidity, 2, raw = T)2  -4.974e-01  1.146e-01  -4.338 1.64e-05 ***
## as.factor(weathersit)2       -3.310e+02  7.370e+01  -4.491 8.28e-06 ***
## as.factor(weathersit)3       -1.414e+03  2.083e+02  -6.791 2.36e-11 ***
## as.factor(mnth)2              4.744e+01  1.405e+02   0.338 0.735760    
## as.factor(mnth)3              5.145e+02  1.528e+02   3.367 0.000802 ***
## as.factor(mnth)4              6.475e+02  1.701e+02   3.808 0.000153 ***
## as.factor(mnth)5              8.068e+02  1.915e+02   4.214 2.84e-05 ***
## as.factor(mnth)6              9.282e+02  2.160e+02   4.298 1.97e-05 ***
## as.factor(mnth)7              1.149e+03  2.381e+02   4.823 1.73e-06 ***
## as.factor(mnth)8              9.351e+02  2.207e+02   4.237 2.57e-05 ***
## as.factor(mnth)9              1.251e+03  1.974e+02   6.338 4.15e-10 ***
## as.factor(mnth)10             1.323e+03  1.710e+02   7.733 3.62e-14 ***
## as.factor(mnth)11             1.076e+03  1.551e+02   6.942 8.77e-12 ***
## as.factor(mnth)12             7.853e+02  1.453e+02   5.406 8.82e-08 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 722.8 on 708 degrees of freedom
## Multiple R-squared:  0.865,  Adjusted R-squared:  0.8608 
## F-statistic: 206.1 on 22 and 708 DF,  p-value: < 2.2e-16

Based upon the about above we can see that we do have a statistically significant increase in riders when a promotion is present. To put that into lay terms, we can say: On days that have a promotion, holding all other potential impacts constant (i.e. weather, temperature, humidity, etc.) we expect, on average, to have an additional 1945 riders using the BikeShare service.

Question 5

To understand how the promotions effect each type of rider, let us redo our model. However, instead of looking at total riders, let us run the model once for casual riders and once for registered riders.

Our first model will be for registered riders. Also for this analysis we will remove the mnth variable, as we already know that it is highly correlated with our other factors and we will add in the working day variable (this variable flags if the day is a working day or a holiday):

## 
## Call:
## lm(formula = registered ~ poly(temp, 3, raw = TRUE) + as.factor(Promotion) + 
##     poly(windspeed, 3, raw = T) + poly(humidity, 2, raw = T) + 
##     as.factor(weathersit) + as.factor(workingday), data = bike_share)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -2877.4  -382.8    -5.4   401.9  1657.9 
## 
## Coefficients:
##                                Estimate Std. Error t value Pr(>|t|)    
## (Intercept)                  -169.56037  588.07791  -0.288   0.7732    
## poly(temp, 3, raw = TRUE)1    -33.59695   62.72418  -0.536   0.5924    
## poly(temp, 3, raw = TRUE)2     16.59063    3.36877   4.925 1.05e-06 ***
## poly(temp, 3, raw = TRUE)3     -0.40699    0.05655  -7.197 1.56e-12 ***
## as.factor(Promotion)1        1649.72243   50.11341  32.920  < 2e-16 ***
## poly(windspeed, 3, raw = T)1 -110.27432   55.65467  -1.981   0.0479 *  
## poly(windspeed, 3, raw = T)2    5.21468    3.85067   1.354   0.1761    
## poly(windspeed, 3, raw = T)3   -0.12155    0.08134  -1.494   0.1355    
## poly(humidity, 2, raw = T)1    50.62143   12.49519   4.051 5.65e-05 ***
## poly(humidity, 2, raw = T)2    -0.52496    0.10267  -5.113 4.07e-07 ***
## as.factor(weathersit)2       -295.82239   66.68532  -4.436 1.06e-05 ***
## as.factor(weathersit)3       -978.28127  187.89765  -5.206 2.52e-07 ***
## as.factor(workingday)1        925.62085   52.93694  17.485  < 2e-16 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 661.2 on 718 degrees of freedom
## Multiple R-squared:  0.8234, Adjusted R-squared:  0.8204 
## F-statistic: 278.9 on 12 and 718 DF,  p-value: < 2.2e-16

##                                 GVIF Df GVIF^(1/(2*Df))
## poly(temp, 3, raw = TRUE)   1.273859  3        1.041167
## as.factor(Promotion)        1.049821  1        1.024608
## poly(windspeed, 3, raw = T) 1.264785  3        1.039927
## poly(humidity, 2, raw = T)  2.726180  2        1.284957
## as.factor(weathersit)       2.260061  2        1.226112
## as.factor(workingday)       1.012821  1        1.006390

##                      bike_share$humidity bike_share$weathersit
## bike_share$temp                0.1269629           -0.12060224
## bike_share$Promotion          -0.1106510           -0.04872654
## bike_share$windspeed          -0.2484891            0.03951106
##                      bike_share$workingday
## bike_share$temp                0.052659810
## bike_share$Promotion          -0.002012621
## bike_share$windspeed          -0.018796487

Based upon the output above we can see that once again the presence of a promotion does have a statistically significant impact to our riders. For our registered riders, keeping all other factors constant, we would expect, on average, ridership to increase by 1650. The output also shoes that over 82% of the variation in registered ridership is explained by our model. We can also see by the crPlots, correlation and the QQPlot that our model doesn’t have high collinearity and that the linear assumptions of our model are not violated. The VIF also shows that we don’t have a high variable inflation.

Now let us take a look at the casual rider model. Again for this model we will remove the mnth factor due to is collinearity and add in working day:

## 
## Call:
## lm(formula = casual ~ poly(temp, 3, raw = TRUE) + as.factor(Promotion) + 
##     poly(windspeed, 3, raw = T) + poly(humidity, 2, raw = T) + 
##     as.factor(weathersit) + as.factor(workingday), data = bike_share)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -971.58 -223.26  -35.37  177.28 1555.50 
## 
## Coefficients:
##                                Estimate Std. Error t value Pr(>|t|)    
## (Intercept)                  1192.36107  312.08730   3.821 0.000145 ***
## poly(temp, 3, raw = TRUE)1    -93.38705   33.28712  -2.806 0.005160 ** 
## poly(temp, 3, raw = TRUE)2     11.51025    1.78778   6.438 2.21e-10 ***
## poly(temp, 3, raw = TRUE)3     -0.24175    0.03001  -8.055 3.31e-15 ***
## as.factor(Promotion)1         258.20551   26.59471   9.709  < 2e-16 ***
## poly(windspeed, 3, raw = T)1  -66.97410   29.53540  -2.268 0.023651 *  
## poly(windspeed, 3, raw = T)2    4.40675    2.04351   2.156 0.031379 *  
## poly(windspeed, 3, raw = T)3   -0.10986    0.04316  -2.545 0.011128 *  
## poly(humidity, 2, raw = T)1     4.13414    6.63108   0.623 0.533187    
## poly(humidity, 2, raw = T)2    -0.10402    0.05449  -1.909 0.056646 .  
## as.factor(weathersit)2        -53.27834   35.38926  -1.505 0.132637    
## as.factor(weathersit)3       -188.40453   99.71548  -1.889 0.059238 .  
## as.factor(workingday)1       -816.51129   28.09312 -29.064  < 2e-16 ***
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 350.9 on 718 degrees of freedom
## Multiple R-squared:  0.7431, Adjusted R-squared:  0.7388 
## F-statistic: 173.1 on 12 and 718 DF,  p-value: < 2.2e-16

##                                 GVIF Df GVIF^(1/(2*Df))
## poly(temp, 3, raw = TRUE)   1.273859  3        1.041167
## as.factor(Promotion)        1.049821  1        1.024608
## poly(windspeed, 3, raw = T) 1.264785  3        1.039927
## poly(humidity, 2, raw = T)  2.726180  2        1.284957
## as.factor(weathersit)       2.260061  2        1.226112
## as.factor(workingday)       1.012821  1        1.006390

##                      bike_share$humidity bike_share$weathersit
## bike_share$temp                0.1269629           -0.12060224
## bike_share$Promotion          -0.1106510           -0.04872654
## bike_share$windspeed          -0.2484891            0.03951106
##                      bike_share$workingday
## bike_share$temp                0.052659810
## bike_share$Promotion          -0.002012621
## bike_share$windspeed          -0.018796487

Again we see from our output that the presence of a promotion does have a statistically significant impact to overall ridership. However, the impact of the promotion is much smaller to our casual riders vs. our registered riders. On average, holding all other factors constant, we would expect our casual ridership to increase by 258 riders with the presence of a promotion. We can also see that almost 74% of casual rider variation can be explained by our model. We can also see by the crPlots, correlation and the QQPlot that our model doesn’t have high collinearity and that the linear assumptions of our model are not horribly violated (although there are some outliers that need to be investigated). Our VIF output also shows that we have very small variable inflation.

Question 6

While we have been able to build a great model that will help us predict total ridership based upon the presence of a promotion, temperature, windspeed, humidity and the weather situation (i.e. raining, snowing, etc.) we still do not full understand the full impact that the promotions have to the BiekShare Company.

In order to better answer this question, we would need access to some more data. The first type of data that we need to get is the conversation rate (or how many casual riders made the switch to registered riders after participating in a promotion). We would also need to understand the profitability of this promotion (if every promotion cost more than is taken in and conversion rate is low, than offering a promotion is not a good financial investment in the long run).

Neighborhood specific data would be helpful also, as this would allow us to understand if this type of promotion works for all riders, or are there other types of promotions that would work better in other areas.

Maintenance cost and theft loss are two other data types that would be good to have. We currently assume that promotions do not cause any significant increase cost in repairs or stolen bicycles. With this data we could validate that claim.