STAT 350: 95-3
Assignment 6
If we fit a simple linear regression of the form
for which the design matrix is as above, evaluate the non-centrality parameter of the t test of when in fact and . What would the power of a two sided 1% level t test of this null hypothesis be? How many times would we have to replicate this design to get a power of 0.9 for a 1% level test?
Solution: We have
and
The variance of is and the non-centrality parameter is . From Table B 5 p 1347 I get a power of 0.31 (3 df for error). If we replicate the design m times we would have a non-centrality parameter of . The infinity line in the table would suggest an m of 1 but because the degrees of freedom is so low we have to do some trial and error. An m of 2 would give a non-centrality parameter of 5.66. There would be 8 degrees of freedom and the power would be around 0.95 so m=2 would be adequate.
Assume that in fact and .
Solution: The non-centrality parameter is
Here , is a matrix with all entries equal to 1/5 and
We find and finally that the non-centrality parameter is 66/2.5=26.4.
The data set in the text has one number different than the data set on the computer disk. The results below are for the data off the disk. Students who took the data from the book got somewhat different results but I marked them right, since they were right for the data they used.
Solution: The fitted line is
a) The residual plot is
This plot suggests that the residuals are bigger when Speed is bigger; this is evidence of heteroscedasticity.
c) The desired plot is
This plot suggests a linear fit of against Speed might work.
d) The regression equation is
The required weights are
0.0146 0.0032 0.0052 0.0032 0.0146 0.0052 0.0052 0.0032 0.0146 0.0032 0.0146 0.0052
e) The weighted least squares regression line is
These estimates are little changed compared to the standard errors.
OLS | WLS | OLS | WLS | |
Parameter | Estimate | Estimate | SE | SE |
Intercept | -5.75 | -6.23 | 16.73 | 13.17 |
Slope | 0.1875 | 0.1891 | 0.0538 | 0.0506 |
f) The standard errors from weighted least squares are rather smaller though more so for the less important parameter, the intercept.
where the errors have variances and the are known quantities. Find an explicit algebraic formula for the weighted least squares estimate of .
Solution: The matrix X is a single column of n ones. The matrix W is diagonal with down the diagonal. The vector WX has entries and finally . Next is the inner product between the vector WX with ith entry and Y with ith entry so . Finally which is what is called a weighted average.