In: Statistics and Probability
Consider the following data between number of visitors x and the amount of wildlife seen in Cheaha State Park y,
visitors | wildlife |
500 | 25 |
450 | 35 |
475 | 30 |
420 | 32 |
555 | 28 |
600 | 22 |
375 | 19 |
(a) Find the mean of x and the mean of y.
(b) Find the standard deviation of x and the standard deviation of y. Use Excel.
(c) Find the correlation coefficient. Use Excel. (d) Find the slope and intercept of the linear regression line. Then write down the line.
(e) Make predictions for all the values of x in the table. Then calculate the residuals.
(f) Calculate the sum of squared residuals. (g) Calculate the standard deviation of the regression.
(h) Using the mean of x and your data for x, calculate the sum of squared deviations.
(i) Write down an appropriate null and alternative hypothesis.
(j) Calculate the test-statistic.
(k) Make a prediction for when x is 470, and calculate (xp − ¯ x)2. Then make a confidence interval around your prediction.
Solution-: Let, x=Number of visitors and y= The amount of wildlife
Given data:
F Column G Column
x | y |
500 | 25 |
450 | 35 |
475 | 30 |
420 | 32 |
555 | 28 |
600 | 22 |
375 | 19 |
(a)
Mean (x) =482.14 ( By using MS-Excel function "=AVERAGE(F2:F8)" )
Mean (y) =27.29 ( By using MS-Excel function "=AVERAGE(G2:G8)" )
(b)
Var (x) = 5134.69 ( By using MS-Excel function "=VARP(F2:F8)" )
SD (x) = 76.66 ( By using MS-Excel function "SQRT()" )
Var (y) = 27.35 ( By using MS-Excel function "=VARP(G2:G8)" )
SD (y) = 5.23 ( By using MS-Excel function "SQRT()" )
(c)
r=Corr(x,y)=-0.11 ( By using MS-Excel function "=CORREL(F2:F8,G2:G8)" )
(d) Find the slope and intercept of the linear regression line by using Data Data Analysis Regresssion in MS-Excel
We get output
SUMMARY OUTPUT | ||||||||
Regression Statistics | ||||||||
Multiple R | 0.108379 | |||||||
R Square | 0.011746 | |||||||
Adjusted R Square | -0.1859 | |||||||
Standard Error | 6.151098 | |||||||
Observations | 7 | |||||||
ANOVA | ||||||||
df | SS | MS | F | Significance F | ||||
Regression | 1 | 2.248524 | 2.248524 | 0.059428 | 0.817089 | |||
Residual | 5 | 189.18 | 37.83601 | |||||
Total | 6 | 191.4286 | ||||||
Coefficients | Standard Error | t Stat | P-value | Lower 95% | Upper 95% | Lower 95.0% | Upper 95.0% | |
Intercept | 31.099 | 15.8149 | 1.966448 | 0.106406 | -9.55432 | 71.75265 | -9.55432 | 71.75265 |
x | -0.008 | 0.032445 | -0.24378 | 0.817089 | -0.09131 | 0.075493 | -0.09131 | 0.075493 |
From this output we get regression line,
y=31.099-0.008*x