lab01, homework 1
 

Homework 1

Review of Basic Regression Computations /* ---------------------------------------Due Sep. 2 2003----------- | This exercise provides a brief review of simple linear regression | | (EXER 1.19) and a review of simple matrix computations. | --------------------------------------------------------------------


Questions Look through sections 1.1-1.6, digesting any information you do not already know about simple linear regression, then...
  1. Ex 1.19 The following data relate soybean seed weight Y, to solar radiation X at two ozone levels. The program steps that follow create a SAS data set with which you can do the necessary computations. Note the use of the '.' to obtain a predicted value for x = 400. For these data, do the following:
    • (A) Answer the questions on page 34.
    • (B) For high ozone and radiation 400, we have used the "missing Y trick" to compute a prediction. Explain how this prediction can be computed from the regression coefficients for the high ozone data.
    • (C) Show how the standard error for this prediction is computed from the inverse of X'X and the error mean square.
    • (D) Explain the difference between a prediction interval for an individual (CLI) and the confidence interval for a mean (CLM). Show the hand computations for our radiation 400, high ozone prediction. You can assume everyone knows how to compute the slope, intercept, error mean square, etc. Just show how these enter the confidence interval formula.
      SAS Code for part 1
  • Work exercises 2.1 and 2.3 on matrix operations. You can use this IML code to help you, but should be able to do everything by hand as well. For your answer to 2.1 (e) explain what SAS is doing and note that this operation would usually be considered "illegal".
    SAS IML Code for part 2
  • Vectors A=(1,8,2)' and B = (-4,1,5)' are obviously in three dimensional space. We can get a three dimensional plot of these as follows

    DATA THREED ; INPUT Y1 Y2 Y3; CARDS; 0 0 0 1 8 2 -4 1 5 PROC G3D; SCATTER Y1*Y2=Y3/NONEEDLE SHAPE ='BALLOON'; RUN;

    Output