Premaster Statistics Tutorial 4 Full solutions Regression analysis Q1 (based on Doane & Seward, 4/E, 12.7) a. Interpret the slope of the fitted regression = 125,000 + 150. b. What is the prediction for if = 2,000? c. Would the intercept be meaningful if this regression applies to home sales in a certain subdivision, different form the one used to find the regression equation? A1 a. Increasing the size of a home by 1 square foot increases the price by $150. b. = $125,000 + ($150 2,000) = $425,000. c. The intercept might be interpreted as the value of the lot without a home. But the range of values for does not include zero so it would be dangerous to extrapolate for = 0. Extra Observe the somewhat confusing habit in economic literarure of writing regression equations in the form = 125,000 + 150, where is a variable, not a unit. Q2 (based on Doane & Seward, 4/E, 12.13) The regression equation = 51.3 + 2.61 was estimated from a sample of 34 cities in the eastern United States. Both variables are in thousands of dollars. is the median selling price of homes in the city, and is median family income for the city. a. Interpret the slope. b. Is the intercept meaningful? Explain. c. Make a prediction of when = 50 and also when = 100. d. Given: =0.3399. What is the meaning of that? (Data are from Money Magazine 32, no. 1 [January 2004], pp. 102 103.) A2 a. Increasing the median income by $1,000 raises the median home price by $2,610; b. If median income is zero, then the model suggests that median home price is $51,300; c. $181,800 and $312,300; d. 34% of the variance of is explained by the model. Sol a. Increasing the median income by $1,000 raises the median home price by $2,610. b. If median income is zero, then the model suggests that median home price is $51,300. While it does not seem logical that the median family income for any city is zero, it is unclear what the lower bound would be. c. prediction HomePrice = $51.3 + (2.61 $50) = $181.8 (in $1000) or $181,800 prediction Homeprice = $51.3 + (2.61 $100) = $312.3 (in $1000) or $312,300 d. 34% of the variance of is explained by the model. That is quite low. And it might be due to chance: perhaps a lucky sample. Fortunately, the latter can be judged by statistical significance. The model is significant if the slope is significantly different from zero: this seems to be the case looking at the -value (see later). Q3 (based on Doane & Seward, 4/E, 12.26) A regression was performed using data on 16 randomly selected charities in 2003. The variables were = expenses (millions of dollars) and = revenue (millions of dollars). a. Write the fitted regression equation. b. Construct a 95 percent confidence interval for the slope. c. Perform a right-tailed test for zero slope at =.05. State the hypotheses clearly. (Data are from Forbes 172, no. 12, p. 248, and www.forbes.com.) PM_STAT 1 Tutorial 4
SUMMARY OUTPUT Regression Statistics Multiple R 0,937926275 R Square 0,879705698 Adjusted R Square 0,871113248 Standard Error 14,63326519 Observations 16 ANOVA df SS MS F Significance F Regression 1 21923,1457 21923,1457 102,3812397 8,07289E-08 Residual 14 2997,8543 214,13245 Total 15 24921 Coefficients Standard Error t Stat P-value Lower 95% Upper 95% Intercept 7,6425 10,0403 Revenue 0,9467 0,0936 A3 a. =7.6425+0.9467 ; b. 0.7460 1.1473; c. reject Sol a. Define : expenses ($1,000,000); : revenue ($1,000,000) a. =7.6425+0.9467 b. For a 95% confidence level use ;. =2.145 The 95% confidence interval is 0.9467±(2.145 0.0936) or 0.7460 1.1473. c. Use our 5-steps procedure: Model ( step 0 ): = + + where ~ (0, ) (i) : 0 versus : >0 ( =0.05) (ii) Sample statistic: ; reject for large values. (iii) Distribution test statistic under : = ~ Assumptions: see model (iv) Calculated test statistic: =. =10.114. Critical value: = ;. =1.761 (v) Because >, reject. There is evidence that the slope is positive; increased revenue is correlated with increased expenses. Q4 Use a linear regression model to explain the height (Dutch: lengte ) of female premaster students (2011-2012) in terms of their shoe size (Dutch: schoenmaat ). Below you find some computer output, based on a random sample of these students. PM_STAT 2 Tutorial 4
Predicted values for: Lengtecm 95% Confidence Interval 95% Prediction Interval Schoenmaat Predicted lower upper lower upper 38 168.307 167.014 169.601 156.911 179.703 A4 Sol a. Determine the theoretical and the estimated model belonging to the given output. b. It is claimed that the slope in this model is larger than 2. Test this hypothesis ( =1%). c. Is this a useful model in order to predict the height of female premaster students? (Perhaps you have seen a footprint in the snow; is it useful (using this model) to predict the height of the person concerned?) d. You see a footprint of size 38 in the snow and looking up you see in the distance a (female) premaster student just walking away. Give a relevant 95% interval for the height of this (female) premaster student. e. The next day you see another footprint of size 38. Give a relevant 95% interval for the average height of all (female) premaster students with shoe size 38. f. Calculate a 90% confidence interval for the constant in the regression model. a. Theoretical model: = + +, with ~ (0, ); Estimated model: = + = 51.386+3.079 ; b. reject ; c. not very useful; d. 156.911,179.703 ; e. 167.014,169.601 ; f. 24.467,78.305 a. Theoretical model: = + +, with ~ (0, ). = height in cm, = shoe size (may be stated for individual observations with or without the subscript ). Estimated model: = + =51.386+3.079 b. Use the 5 steps procedure! step 0 (model): see a. (i) : 2; : >2; =1% (ii) Sample statistic: ; reject for large values (iii) Distribution test statistic under : = ~ = ( =91) Assumptions: see model. We do not really need normality because is so large. (iv) Calculated test statistic: =. =2.573. PM_STAT 3 Tutorial 4
Critical value: = ;. =2.3690 using Excel. With the table, you may take a conservative value ;. =2.371 -value: 0.0059 (using Excel) (v) Decision: do reject, because -value smaller than 1% or because >. Conclude that the slope is larger than 2. c. It is a statistically significant model, so the question about practically relevant is meaningful. We have =0.3772 which is quite low. It would have quite limited value in predicting the height of a thief if the police found a footprint in the snow. d. This is individual prediction : 156.911 179.703. e. This is mean prediction : 167.014 169.601. f. ± ;. =51.386±(1.662 16.195), so 24.467 78.305 (Excel: ;. =1.662155) Q5 A consumer products company wants to measure the effectiveness of different types of advertising media in the promotion of its products. Specifically, the company is interested in the effectiveness of radio advertising and newspaper advertising (including the cost of discount coupons). A sample of 22 cities with approximately equal populations is selected for study during a test period of one month. Each city is allocated a specific expenditure level both for radio advertising and for newspaper advertising. The sales of the product (in thousands of dollars) and also the levels of media expenditure (in thousands of dollars) during the test month are recorded, with the following results: SPSS results: PM_STAT 4 Tutorial 4
a. State the multiple regression equation (description of the model including assumptions and the estimated model). b. Interpret the meaning of the slopes, and, in this problem. c. Interpret the meaning of the regression coefficient,. d. Which type of advertising is more effective? Explain. e. Determine whether there is a significant relationship between sales and the two independent variables (radio advertising and newspaper advertising) at the 0.05 level of significance. f. Interpret the meaning of the -value. g. Compute the coefficient of multiple determination,, and interpret its meaning. h. Find the adjusted and interpret its meaning. i. Is there evidence that the slope coefficient for Radio advertisements is more than 10 at = 0.05? A5 A. = + + + with ~ (0, ) and = + + =156.430+ 13.081 +16.795 ; d. newspaper advertising is more effective; e. there is evidence of a significant linear relationship; i. there is evidence that the coefficient for radio advertisements is larger than 10. Sol a. Statistical model: = + + + with ~ (0, ^2) where =Sales, =Radio Advertising, =Newspaper Advertising Estimated model: = + + =156.430+13.081 +16.795 where =Estimated Sales b. For a given amount of newspaper advertising, each increase of $1000 in radio advertising is estimated to result in a mean increase in sales of $13,081. For a given amount of radio advertising, each increase of $1000 in newspaper advertising is estimated to result in the mean increase in sales of $16,795. c. When there is no money spent on radio advertising and newspaper advertising, the estimated mean amount of sales is $156,430.44. PM_STAT 5 Tutorial 4
d. The slope of newspaper advertising is higher than the slope of radio advertising, so newspaper advertising is more effective. e. Model: see a. (i) : = =0; :not ; =0.05 (ii) Sample statistic: = ; reject for large values (iii) Under : ~, Assumptions: see model formulation (error term normally distributed with constant variance) (iv) = =40.16;. =3.522; -value=0.000 (v) reject because > or equivalently because <. Conclude that there is evidence of a significant linear relationship. f. -value<0.0005: the probability of obtaining an of 40.16 or even larger is less than 0.0005 if is true. g. = = =0.8087, or rather directly from SPSS output. So, 80.87% of the variation in sales can be explained by variation in radio advertising and variation in newspaper advertising. Note: model is significant and =0.81, so practically it is a useful model. h. =0.789 from computer output. This is the proportion of explained variance, but taking into account the number of variables and number of observations. i. This test is not provided by SPSS, but is not difficult to derive from it. (i) : 10 against : >10 ( =0.05) (ii) Sample statistic: ; reject for large values. (iii) Under : ~ ; assumptions: see earlier. (iv) =. =1.7516;. = ;. =1.7291 (v) Reject because >. There is evidence that the coefficient for radio advertisements is larger than 10. Regression diagnostics Q1 (Doane & Seward, 4/E, 12.37) An estimated regression for a random sample of vehicles is =49.22 0.081, where is miles per gallon and is the engine s horsepower. The standard error is =2.03. Suppose an engine has 200 horsepower and its actual (observed) fuel efficiency is =38.15. a. Calculate the predicted. b. Calculate the residual. c. Standardize the residual using. d. Is this engine an outlier? A1 a. 33.02; b.5.13; c. 2.527; d. an unusual observation, not an outlier Sol a. =49.22 0.081 200=33.02. b. = =38.15 33.02=5.13 c. = =. =2.527.. d. 2< <3, so we refer to this engine as an unusual observation, not as an outlier. Q2 (Doane & Seward, 4/E, 12.38) A sample of season performance measures for 29 NBA teams was collected for a season. A regression analysis was performed on two of the variables with = total number of free throws made and = total number of free throws attempted. Calculate the leverage statistic for the PM_STAT 6 Tutorial 4
A2 Sol Q3 following three teams and state whether or not the leverage would be considered high. Given: =999,603 and =2004. a. The Golden State Warriors attempted 2,382 free throws. b. The New Jersey Nets attempted 2,125 free throws. c. The New York Knicks attempted 1,620 free throws. a. Yes; b. No; c. Yes a. h= +( ) = +( ) =0.18. The value of = =0.14, so this observation has a high leverage statistic. b. h= +( ) = +( ) =0.05. The value of = =0.14, so this observation does not have a high leverage statistic. c. h= +( ) = +( ) =0.18. See a. A consumer products company wants to measure the effectiveness of different types of advertising media in the promotion of its products. Specifically, the company is interested in the effectiveness of radio advertising and newspaper advertising (including the cost of discount coupons). A sample of 22 cities with approximately equal populations is selected for study during a test period of one month. Each city is allocated a specific expenditure level both for radio advertising and for newspaper advertising. The sales of the product (in thousands of dollars) and also the levels of media expenditure (in thousands of dollars) during the test month are recorded, with the following results: SPSS output is given below: PM_STAT 7 Tutorial 4
a. State the multiple regression equation (description of the the model including assumptions and the estimated model). b. Interpret the meaning of the slopes, and, in this problem. c. Interpret the meaning of the regression coefficient,. d. Which type of advertising is more effective? Explain. e. Determine whether there is a significant relationship between sales and the two independent variables (radio advertising and newspaper advertising) at the 0.05 level of significance. f. Interpret the meaning of the -value. g. Compute the coefficient of multiple determination,, and interpret its meaning. h. Find the adjusted and interpret its meaning. i. Perform a residual analysis on your results. PM_STAT 8 Tutorial 4
j. If appropriate, perform the Durbin-Watson test using =0.05. k. Are the regression assumptions valid for these data? l. Construct a 95% confidence interval estimate of the population slope between sales and radio advertising. m. At the 0.05 level of significance, determine whether each independent variable makes a significant contribution to the regression model. On the basis of these results, indicate the independent variables to include in this model, using statistical significance as the only criterion. n. Test : 10 against : >10 (or is there evidence that the slope coefficient for Radio is more than 10?) o. Is there serious collinearity? p. Some might argue that there is a pattern in the residuals, suggesting a quadratic relation between sales and both advertising variables. We computed the variables and and included these variables in the regression model. State the model and the estimated model. Compare the two models. PM_STAT 9 Tutorial 4
q. Any comments on the residual for this model? A3 See full solutions. Sol a. Model: = + + +, ~ (0, ), =Sales, =Radio Advertising, =Newspaper Advertising; =156.430+13.081 +16.795 b. For a given amount of newspaper advertising, each increase of $1000 in radio advertising is estimated to result in a mean increase in sales of $13,081. For a given amount of radio advertising, each increase of $1000 in newspaper advertising is estimated to result in the mean increase in sales of $16,795. c. When there is no money spent on radio advertising and newspaper advertising, the estimated mean amount of sales is $156,430.44. PM_STAT 10 Tutorial 4
d. Technically you would need : = which is outside our scope. Just look at magnitude of slope coefficient: newspaper is more effective. e. Five (six?) steps procedure: (0) Model: = + + +, ~ (0, ), =Sales, =Radio Advertising, =Newspaper Advertising (1) : = =0; : ( = =0); =0.05 (2) Sample statistic: = ; reject for large values (3) Under : ~ ; ; assumptions: see model formulation in step (0) (4) = =40.158;. = ; ;. =3.522; -value=0.000 (5) > or -value<, so reject and conclude that there is evidence of a significant linear relationship. f. -value<0.0005. The probability of obtaining an test statistic of 40.16 or larger is less than 0.0005 if is true. g. = =,, =0.8087, or rather directly from SPSS output. So, 80.87% of the,, variation in sales can be explained by variation in radio advertising and variation in newspaper advertising. Note: model is significant and =0.81, so practically it is a useful model. h. =0.789 from computer output. This is proportion of explained variance, but taking into account the number of variables and number of observations. (In samples -squared will be somewhat inflated (biased upward), while -squared adjusted is not). i. There appears (not very clear!) to be a quadratic relationship in the plot of the residuals against both radio and newspaper advertising. Thus, quadratic terms for each of these explanatory models should be considered for inclusion in the model. j. Durbin-Watson has no meaning here, as there is no natural ordering of the 22 cases. k. The skewness and kurtosis of the residual are pretty well between 1 and 1. This l. 95% confidence interval on : ± =13.0807±2.093 1.7594. Alternative notation 9.398 16.763, of = 9.398,16.763 m. First test : (1) : =0; : 0; =0.05 (2) Sample statistic: ; reject for large and small values (3) Under : = ~ = ; assumptions: see previous model formulation (4) =. =7.43;. = ;. =2.093; -value=0.000 (5) Reject because -value=0.000 0.05= There is evidence that the variable contributes to a model already containing. Now for : (4) =. =5.67;. = ;. =2.093; -value=0.000 (5) Reject because -value=0.000 0.05= There is evidence that the variable contributes to a model already containing. n. (1) : 10; : >10; =0.05 (4) = normal calculator. =.. =1.7516; =1.7291. A -value cannot be computed with a (5) Reject because >. There is evidence that the coefficient is larger than 10. o. =0.008464, = =1.009 or directly from output. =1.009. There is no serious collinearity as the VIF is smaller than 5 (even close to 1, the minimum value!). For the results are identical. can be computed by regressing on all remaining explanatory PM_STAT 11 Tutorial 4
variables ( ). Both VIFs are equal because we have only two explanatory variables in this model. p. Model: = + + + + +, ~ (0, ), =Sales, =Radio Advertising, =Newspaper Advertising Note =0.907, considerably larger than =0.789 in smaller model. Not all variables are significant anymore, perhaps due to the substantial multicollinearity (VIFs are 13.4, 9.1, 13.4 and 9.45, all considerably larger than 5). You perhaps could eliminate the variables and (the linear, non-significant terms, and you end up with the model below, which is very good. q. The skewness and kurtosis statistics look fine, well between 1 and 1. There is no sign of heteroscedasticity. PM_STAT 12 Tutorial 4