EXST7005 Fall2010 22b Appendix 08 & 09

EXST7005 Fall2010 22b Appendix 08 & 09 -...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Statistical Methods I (EXST 7005) 1 2 3 Appendix 8 Page 222 TITLE1 'Appendix of Simple linear Regression (SLR)'; dm'log;clear;output;clear'; 4 ODS HTML style=minimal body='C:\EXST7005\Spring2010\SAS\Appendix08.html'; NOTE: Writing HTML Body file: C:\EXST7005\Spring2010\SAS\Appendix08.html 5 ODS RTF style=minimal body='C:\EXST7005\Spring2010\SAS\Appendix08.rtf' ; NOTE: Writing RTF Body file: C:\EXST7005\Spring2010\SAS\Appendix08.rtf 6 ODS PDF style=minimal body='C:\EXST7005\Spring2010\SAS\Appendix08.PDF' ; NOTE: Writing ODS PDF output to DISK destination "C:\EXST7005\Spring2010\SAS\Appendix08.PDF", printer "PDF". 7 8 ***************************************************************; 9 *** EXST7005 Regression Appendix ***; 10 *** Redfin Pickerel, and other fish, accumulate parasites ***; 11 *** on their fins. These parasites attach and stay with ***; 12 *** the fish throughout its life until the fish is eaten ***; 13 *** and the parasite continues its life cycle. ***; 14 *** - - - - - - - - - - - - - - - - - - - - - - - - - - - - ***; 15 *** If parasites are accumulated at a constant rate, older ***; 16 *** fish should have more parasites. Test this hypothesis. ***; 17 *** OBJECTIVES: ***; 18 *** 1) Determine if older fish have more parasites. ***; 19 *** 2) Estimate the rate of accumulation of parasites. ***; 20 *** 3) Place a confidence interval on this estimate ***; 21 *** 4) Estimate the intercept with confidence interval. ***; 22 *** 5) How many parasites a 10 year old fish would have. ***; 23 *** 6) Put a confidence interval on the 10 year old fish ***; 24 *** 7) Determine of a linear model is adequate. ***; 25 *** 8) An old published article states that the rate ***; 26 *** should be about 5 per year. Test this. ***; 27 ***************************************************************; 28 29 options ps=256 ls=99 nocenter nodate nonumber nolabel; 30 31 DATA ONE; INFILE CARDS MISSOVER; 32 TITLE2 'Rate of parasite accumulation in Redfin Pickerel'; 33 INPUT AGE PARASITE; 34 LABEL AGE = 'Fish age from scales reading'; 35 LABEL PARASITE = 'Pectoral fin parasites / sq cm'; 36 CARDS; NOTE: The data set WORK.ONE has 18 observations and 2 variables. NOTE: DATA statement used (Total process time): real time 0.00 seconds cpu time 0.00 seconds 55 ; 56 PROC PRINT DATA=ONE; 57 TITLE3 'Data Listing for Fish Parasite Regression'; RUN; NOTE: There were 18 observations read from the data set WORK.ONE. NOTE: The PROCEDURE PRINT printed page 1. NOTE: PROCEDURE PRINT used (Total process time): real time 0.07 seconds cpu time 0.00 seconds James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 8 Page 223 Example of Simple linear Regression (SLR) Rate of parasite accumulation in Redfin Pickerel Data Listing for Fish Parasite Regression Obs 1 2 3 4 5 6 7 8 9 AGE 1 2 3 3 3 4 4 5 6 PARASITE 3 7 8 12 10 15 14 16 17 10 11 12 13 14 15 16 17 18 6 6 7 7 8 9 9 0 10 15 16 19 21 18 17 20 . . 59 PROC REG DATA=ONE LINEPRINTER; 60 TITLE3 'Fish Parasite Appendix using REG with CLM'; 61 MODEL PARASITE=AGE / clb; *** CLI CLM P R; ID AGE; 62 TEST AGE=5; 63 OUTPUT OUT=NEXT P=Predicted R=Resid STUDENT=student rstudent=rstudent 64 lcl=lcl lclm=lclm ucl=ucl uclm=uclm; 65 RUN; 65 ! OPTIONS PS=45; TITLE4 'Plots of raw data & residuals'; 66 PLOT PREDICTED.*AGE='P' PARASITE*AGE='O' / OVERLAY; 67 PLOT RESIDUAL.*AGE='E'; 68 RUN; 68 ! QUIT; NOTE: The data set WORK.NEXT has 18 observations and 10 variables. NOTE: The PROCEDURE REG printed pages 2-5. NOTE: PROCEDURE REG used (Total process time): real time 0.29 seconds cpu time 0.10 seconds Appendix of Simple linear Regression (SLR) Rate of parasite accumulation in Redfin Pickerel Fish Parasite Appendix using REG with CLM The REG Procedure Model: MODEL1 Dependent Variable: PARASITE Number of Observations Read Number of Observations Used Number of Observations with Missing Values Analysis of Variance Source Model Error Corrected Total Root MSE Dependent Mean Coeff Var DF 1 14 15 2.34598 14.25000 16.46299 Parameter Estimates Parameter Variable DF Estimate Intercept 1 4.77125 AGE 1 1.82723 18 16 2 Sum of Squares 301.94955 77.05045 379.00000 R-Square Adj R-Sq Standard Error 1.40769 0.24669 Mean Square 301.94955 5.50360 F Value 54.86 Pr > F <.0001 0.7967 0.7822 t Value 3.39 7.41 Pr > |t| 0.0044 <.0001 95% Confidence Limits 1.75205 7.79045 1.29813 2.35632 James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 8 Page 224 Appendix of Simple linear Regression (SLR) Rate of parasite accumulation in Redfin Pickerel Fish Parasite Appendix using REG with CLM The REG Procedure Model: MODEL1 Test 1 Results for Dependent Variable PARASITE Mean Source DF Square F Value Numerator 1 910.38705 165.42 Denominator 14 5.50360 Pr > F <.0001 -----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+-----P PRED | | r | | e 25 + + d | | i | | c | | t | O P | e 20 + O + d | O P | | P O | V | O O | a | O ? | l 15 + O O + u | O P | e | | | O P | o | | f 10 + ? + | | P | P O | A | P O | R | | A 5 + + S | | I | O | T | | E | | 0 + + | | -----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+-----1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0 6.5 7.0 7.5 8.0 8.5 9.0 AGE R e s i d u a l ---+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+---RESIDUAL | | | | 4 + + | E | | | | E | | | 2 + E E + | E E | | E | | | | E | 0 + + | E | | E | | E E | | E | -2 + + | E | | | | | | E | -4 + + | E | | | | | | | -6 + + | | ---+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+----+---1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0 5.5 6.0 6.5 7.0 7.5 8.0 8.5 9.0 AGE James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 8 Page 225 70 proc plot data=next; plot rstudent*age / vref = -2.145 0 +2.145; 71 TITLE4 'Plots of deleted standardized residuals with 95% interval'; 72 run; 73 74 OPTIONS PS=256; NOTE: There were 18 observations read from the data set WORK.NEXT. NOTE: The PROCEDURE PLOT printed page 6. NOTE: PROCEDURE PLOT used (Total process time): real time 0.09 seconds cpu time 0.03 seconds Appendix of Simple linear Regression (SLR) Rate of parasite accumulation in Redfin Pickerel Fish Parasite Appendix using REG with CLM Plots of deleted standardized residuals with 95% interval Plot of rstudent*AGE. Legend: A = 1 obs, B = 2 obs, etc. rstudent | 3 + | | | |------------------------------------------------------------------------------------2 + | | A | A | 1 + A | A A | A A | | A 0 +------------------------------------------------------------------------------------| A | A | A A A | -1 + A | | | | -2 + A |------------------------------------------------------------------------------------| A | | -3 + ---+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-0 1 2 3 4 5 6 7 8 9 10 AGE NOTE: 2 obs had missing values. 75 76 77 proc print data=next; TITLE4 'Listing of output from PROC REG'; var age parasite Predicted Resid student rstudent lcl ucl lclm uclm; run; NOTE: There were 18 observations read from the data set WORK.NEXT. NOTE: The PROCEDURE PRINT printed page 7. NOTE: PROCEDURE PRINT used (Total process time): real time 0.09 seconds cpu time 0.03 seconds James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 8 Page 226 Appendix of Simple linear Regression (SLR) Rate of parasite accumulation in Redfin Pickerel Fish Parasite Appendix using REG with CLM Listing of output from PROC REG Obs 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 AGE 1 2 3 3 3 4 4 5 6 6 6 7 7 8 9 9 0 10 PARASITE 3 7 8 12 10 15 14 16 17 15 16 19 21 18 17 20 . . Predicted 6.5985 8.4257 10.2529 10.2529 10.2529 12.0802 12.0802 13.9074 15.7346 15.7346 15.7346 17.5619 17.5619 19.3891 21.2163 21.2163 4.7713 23.0435 Resid -3.59848 -1.42571 -2.25294 1.74706 -0.25294 2.91983 1.91983 2.09261 1.26538 -0.73462 0.26538 1.43815 3.43815 -1.38908 -4.21631 -1.21631 . . student -1.77879 -0.66902 -1.02107 0.79180 -0.11464 1.29626 0.85231 0.92144 0.55925 -0.32468 0.11729 0.64577 1.54382 -0.64222 -2.03920 -0.58826 . . rstudent -1.94833 -0.65524 -1.02274 0.78068 -0.11052 1.33156 0.84348 0.91614 0.54503 -0.31405 0.11308 0.63176 1.63316 -0.62818 -2.34368 -0.57400 . . lcl 0.9586 2.9719 4.9389 4.9389 4.9389 6.8558 6.8558 8.7200 10.5304 10.5304 10.5304 12.2875 12.2875 13.9934 15.6514 15.6514 -1.0967 17.2657 ucl 12.2384 13.8795 15.5670 15.5670 15.5670 17.3046 17.3046 19.0948 20.9389 20.9389 20.9389 22.8362 22.8362 24.7848 26.7812 26.7812 10.6392 28.8213 lclm 4.0507 6.3218 8.5436 8.5436 8.5436 10.6741 10.6741 12.6456 14.4053 14.4053 14.4053 15.9801 15.9801 17.4406 18.8391 18.8391 1.7520 20.2035 uclm 9.1463 10.5296 11.9623 11.9623 11.9623 13.4863 13.4863 15.1692 17.0640 17.0640 17.0640 19.1436 19.1436 21.3376 23.5936 23.5936 7.7905 25.8836 79 PROC UNIVARIATE DATA=NEXT NORMAL PLOT; VAR Resid; 80 TITLE4 'Residual analysis with PROC UNIVARIATE'; 81 RUN; NOTE: The PROCEDURE UNIVARIATE printed page 8. NOTE: PROCEDURE UNIVARIATE used (Total process time): real time 0.12 seconds cpu time 0.04 seconds Appendix of Simple linear Regression (SLR) Rate of parasite accumulation in Redfin Pickerel Fish Parasite Appendix using REG with CLM Residual analysis with PROC UNIVARIATE The UNIVARIATE Procedure Variable: Resid Moments N Mean Std Deviation Skewness Uncorrected SS Coeff Variation 16 0 2.26642816 -0.3183952 77.0504492 . Sum Weights Sum Observations Variance Kurtosis Corrected SS Std Error Mean Basic Statistical Measures Location Variability Mean 0.000000 Std Deviation Median 0.006220 Variance Mode . Range Interquartile Range Tests for Location: Mu0=0 Test -StatisticStudent's t t 0 Sign M 0 Signed Rank S 4 16 0 5.13669661 -0.7591259 77.0504492 0.56660704 2.26643 5.13670 7.65446 3.24084 -----p Value-----Pr > |t| 1.0000 Pr >= |M| 1.0000 Pr >= |S| 0.8603 James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Tests for Normality Test Shapiro-Wilk Kolmogorov-Smirnov Cramer-von Mises Anderson-Darling Appendix 8 --Statistic--W 0.961962 D 0.149185 W-Sq 0.038869 A-Sq 0.248615 Page 227 -----p Value-----Pr < W 0.6975 Pr > D >0.1500 Pr > W-Sq >0.2500 Pr > A-Sq >0.2500 Quantiles (Definition 5) Quantile 100% Max 99% 95% 90% 75% Q3 50% Median 25% Q1 10% 5% 1% 0% Min Estimate 3.43814789 3.43814789 3.43814789 2.91983414 1.83344851 0.00621977 -1.40739461 -3.59847961 -4.21630961 -4.21630961 -4.21630961 Extreme Observations ------Lowest----Value Obs -4.21631 15 -3.59848 1 -2.25294 3 -1.42571 2 -1.38908 14 -----Highest----Value Obs 1.74706 4 1.91983 7 2.09261 8 2.91983 6 3.43815 13 Missing Values Missing Value . Stem 3 2 1 0 -0 -1 -2 -3 -4 Count 2 -----Percent Of----Missing All Obs Obs 11.11 100.00 Leaf Boxplot 4 19 3479 3 73 442 3 6 2 ----+----+----+----+ 1 2 4 1 2 3 1 1 1 | | +-----+ *--+--* | | +-----+ | | | Normal Probability Plot 3.5+ ++++* | +*++* | * *+*+* | +*+++ -0.5+ ++** | *+*+* | +++*+ | ++++* -4.5+ ++++* +----+----+----+----+----+----+----+----+----+----+ -2 -1 0 +1 +2 James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 9 Page 228 1 title1 'Generic multiple regression introduction'; 2 dm'log;clear;output;clear'; 3 4 ODS HTML style=minimal body='C:\EXST 7005\SAS\Example09.html' ; NOTE: Writing HTML Body file: C:\EXST 7005\SAS\Example09.html 5 ODS RTF style=minimal body='C:\EXST 7005\SAS\Example09.rtf'; NOTE: Writing RTF Body file: C:\EXST 7005\SAS\Example09.rtf 6 ODS PDF style=minimal body='C:\EXST 7005\SAS\Example09.PDF'; NOTE: Writing ODS PDF output to DISK destination "C:\EXST 7005\SAS\Example09.PDF", printer "PDF". 7 8 ****************************************************; 9 *** Multiple Regression : Small Generic Example ***; 10 ****************************************************; 11 options ps=256 ls=99 nocenter nodate nonumber; 12 13 data one; infile cards missover; 14 input Y X1 X2 X3; 15 cards; NOTE: The data set WORK.ONE has 12 observations and 4 variables. NOTE: DATA statement used (Total process time): real time 0.01 seconds cpu time 0.01 seconds 15 ! run; 28 ; 29 proc print data=one; title2 'Raw data listing'; run; NOTE: There were 12 observations read from the data set WORK.ONE. NOTE: The PROCEDURE PRINT printed page 1. NOTE: PROCEDURE PRINT used (Total process time): real time 0.18 seconds cpu time 0.01 seconds Generic multiple regression introduction Raw data listing Obs 1 2 3 4 5 6 Y 1 3 5 3 6 4 X1 2 4 7 3 5 3 X2 9 6 7 5 8 4 X3 2 5 9 5 9 2 7 8 9 10 11 12 2 8 9 3 5 6 2 6 7 8 7 9 3 2 5 2 3 1 6 1 3 4 7 4 James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 9 Page 229 30 31 title2 'All possible models with PROC REG'; 32 proc reg data=one; model y = x1/ ss1 ss2; run; NOTE: The PROCEDURE REG printed page 2. NOTE: PROCEDURE REG used (Total process time): real time 0.10 seconds cpu time 0.01 seconds Generic multiple regression introduction All possible models with PROC REG The REG Procedure Model: MODEL1 Dependent Variable: Y Number of Observations Read Number of Observations Used 12 12 Analysis of Variance Source Model Error Corrected Total Root MSE Dependent Mean Coeff Var DF 1 10 11 1.97330 4.58333 43.05377 Parameter Estimates Parameter Variable DF Estimate Intercept 1 1.37613 X1 1 0.61089 Sum of Squares 23.97763 38.93904 62.91667 R-Square Adj R-Sq Standard Error 1.41242 0.24618 Mean Square 23.97763 3.89390 F Value 6.16 Pr > F 0.0325 0.3811 0.3192 t Value 0.97 2.48 Pr > |t| 0.3529 0.0325 Type I SS 252.08333 23.97763 Type II SS 3.69640 23.97763 33 proc reg data=one; model y = x2 / ss1 ss2; run; NOTE: The PROCEDURE REG printed page 3. NOTE: PROCEDURE REG used (Total process time): real time 0.12 seconds cpu time 0.01 seconds NOTE: The PROCEDURE GLM printed pages 10-11. NOTE: PROCEDURE GLM used (Total process time): real time 0.47 seconds cpu time 0.06 seconds Generic multiple regression introduction All possible models with PROC REG The REG Procedure Model: MODEL1 Dependent Variable: Y Number of Observations Read Number of Observations Used 12 12 James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 9 Page 230 Analysis of Variance Sum of Source Model Error Corrected Total Root MSE Dependent Mean Coeff Var DF 1 10 11 2.42490 4.58333 52.90691 Parameter Estimates Parameter Variable DF Estimate Intercept 1 5.68743 X2 1 -0.24089 Squares 4.11526 58.80141 62.91667 R-Square Adj R-Sq Standard Error 1.49393 0.28795 Mean Square 4.11526 5.88014 F Value 0.70 Pr > F 0.4224 0.0654 -0.0281 t Value 3.81 -0.84 Pr > |t| 0.0034 0.4224 Type I SS 252.08333 4.11526 Type II SS 85.22336 4.11526 34 proc reg data=one; model y = x3 / ss1 ss2; run; NOTE: The PROCEDURE REG printed page 4. NOTE: PROCEDURE REG used (Total process time): real time 0.20 seconds cpu time 0.01 seconds Generic multiple regression introduction All possible models with PROC REG The REG Procedure Model: MODEL1 Dependent Variable: Y Number of Observations Read Number of Observations Used 12 12 Analysis of Variance Source Model Error Corrected Total Root MSE Dependent Mean Coeff Var DF 1 10 11 2.50359 4.58333 54.62385 Parameter Estimates Parameter Variable DF Estimate Intercept 1 4.84809 X3 1 -0.05574 Sum of Squares 0.23689 62.67978 62.91667 R-Square Adj R-Sq Standard Error 1.54176 0.28671 Mean Square 0.23689 6.26798 F Value 0.04 Pr > F 0.8498 0.0038 -0.0959 t Value 3.14 -0.19 Pr > |t| 0.0104 0.8498 Type I SS 252.08333 0.23689 Type II SS 61.97728 0.23689 35 proc reg data=one; model y = x1 x2 / ss1 ss2; run; NOTE: The PROCEDURE REG printed page 5. NOTE: PROCEDURE REG used (Total process time): real time 0.17 seconds cpu time 0.01 seconds James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 9 Page 231 Generic multiple regression introduction All possible models with PROC REG The REG Procedure Model: MODEL1 Dependent Variable: Y Number of Observations Read Number of Observations Used 12 12 Analysis of Variance Source Model Error Corrected Total Root MSE Dependent Mean Coeff Var DF 2 9 11 2.07745 4.58333 45.32619 Parameter Estimates Parameter Variable DF Estimate Intercept 1 1.07558 X1 1 0.63159 X2 1 0.04187 Sum of Squares 24.07446 38.84220 62.91667 R-Square Adj R-Sq Standard Error 2.49743 0.29369 0.27955 Mean Square 12.03723 4.31580 F Value 2.79 Pr > F 0.1141 0.3826 0.2454 t Value 0.43 2.15 0.15 Pr > |t| 0.6768 0.0600 0.8842 Type I SS 252.08333 23.97763 0.09684 Type II SS 0.80049 19.95921 0.09684 36 proc reg data=one; model y = x1 x3 / ss1 ss2; run; NOTE: The PROCEDURE REG printed page 6. NOTE: PROCEDURE REG used (Total process time): real time 0.26 seconds cpu time 0.03 seconds Generic multiple regression introduction All possible models with PROC REG The REG Procedure Model: MODEL1 Dependent Variable: Y Number of Observations Read Number of Observations Used 12 12 Analysis of Variance Source Model Error Corrected Total Root MSE Dependent Mean Coeff Var DF 2 9 11 2.04249 4.58333 44.56341 Parameter Estimates Parameter Variable DF Estimate Intercept 1 1.91576 X1 1 0.63161 X3 1 -0.13650 Sum of Squares 25.37078 37.54588 62.91667 R-Square Adj R-Sq Standard Error 1.73473 0.25732 0.23621 Mean Square 12.68539 4.17176 F Value 3.04 Pr > F 0.0980 0.4032 0.2706 t Value 1.10 2.45 -0.58 Pr > |t| 0.2981 0.0365 0.5775 Type I SS 252.08333 23.97763 1.39316 Type II SS 5.08794 25.13390 1.39316 James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 9 Page 232 37 proc reg data=one; model y = x2 x3 / ss1 ss2; run; NOTE: The PROCEDURE REG printed page 7. NOTE: PROCEDURE REG used (Total process time): real time 0.29 seconds cpu time 0.07 seconds Generic multiple regression introduction All possible models with PROC REG The REG Procedure Model: MODEL1 Dependent Variable: Y Number of Observations Read Number of Observations Used 12 12 Analysis of Variance Source Model Error Corrected Total Root MSE Dependent Mean Coeff Var Sum of Squares 4.13721 58.77946 62.91667 DF 2 9 11 2.55559 4.58333 55.75837 Parameter Estimates Parameter Variable DF Estimate Intercept 1 5.62891 X2 1 -0.24662 X3 1 0.01784 R-Square Adj R-Sq Standard Error 1.87021 0.31913 0.30776 Mean Square 2.06860 6.53105 F Value 0.32 Pr > F 0.7363 0.0658 -0.1419 t Value 3.01 -0.77 0.06 Pr > |t| 0.0147 0.4595 0.9550 Type I SS 252.08333 4.11526 0.02195 Type II SS 59.16272 3.90032 0.02195 38 proc reg data=one; model y = x1 x2 x3 / ss1 ss2; run; 39 NOTE: The PROCEDURE REG printed page 8. NOTE: PROCEDURE REG used (Total process time): real time 0.20 seconds cpu time 0.06 seconds Generic multiple regression introduction All possible models with PROC REG The REG Procedure Model: MODEL1 Dependent Variable: Y Number of Observations Read Number of Observations Used Source Model Error Corrected Total Root MSE Dependent Mean Coeff Var DF 3 8 11 12 12 Analysis of Variance Sum of Mean Squares Square 26.18995 8.72998 36.72672 4.59084 62.91667 2.14262 4.58333 46.74817 R-Square Adj R-Sq F Value 1.90 Pr > F 0.2078 0.4163 0.1974 James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Parameter Estimates Parameter Variable DF Estimate Intercept 1 1.14454 X1 1 0.70578 X2 1 0.13483 X3 1 -0.18621 Appendix 9 Standard Error 2.57778 0.32202 0.31918 0.27431 t Value 0.44 2.19 0.42 -0.68 Page 233 Pr > |t| 0.6688 0.0598 0.6838 0.5164 Type I SS 252.08333 23.97763 0.09684 2.11548 Type II SS 0.90503 22.05274 0.81916 2.11548 40 proc mixed data=one; model y = x1 x2 x3 / solution HType=1 2 3; 41 title2 'Multiple Regression with PROC MIXED'; 42 run; NOTE: The PROCEDURE MIXED printed page 9. NOTE: PROCEDURE MIXED used (Total process time): real time 0.10 seconds cpu time 0.03 seconds Generic multiple regression introduction Multiple Regression with PROC MIXED The Mixed Procedure Model Information Data Set Dependent Variable Covariance Structure Estimation Method Residual Variance Method Fixed Effects SE Method Degrees of Freedom Method WORK.ONE Y Diagonal REML Profile Model-Based Residual Dimensions Covariance Parameters Columns in X Columns in Z Subjects Max Obs Per Subject Number Number Number Number of of of of 1 4 0 1 12 Observations Observations Read Observations Used Observations Not Used 12 12 0 Covariance Parameter Estimates Cov Parm Estimate Residual 4.5908 Fit Statistics -2 Res Log Likelihood AIC (smaller is better) AICC (smaller is better) BIC (smaller is better) 49.7 51.7 52.3 51.7 James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 9 Solution for Fixed Effects Standard Effect Estimate Error Intercept 1.1445 2.5778 X1 0.7058 0.3220 X2 0.1348 0.3192 X3 -0.1862 0.2743 DF 8 8 8 8 Page 234 t Value 0.44 2.19 0.42 -0.68 Type 1 Tests of Fixed Effects Num Den Effect DF DF F Value X1 1 8 5.22 X2 1 8 0.02 X3 1 8 0.46 Pr > F 0.0516 0.8881 0.5164 Type 2 Tests of Fixed Effects Num Den Effect DF DF F Value X1 1 8 4.80 X2 1 8 0.18 X3 1 8 0.46 Pr > F 0.0598 0.6838 0.5164 Type 3 Tests of Fixed Effects Num Den Effect DF DF F Value X1 1 8 4.80 X2 1 8 0.18 X3 1 8 0.46 Pr > |t| 0.6688 0.0598 0.6838 0.5164 Pr > F 0.0598 0.6838 0.5164 43 proc glm data=one; model y = x1 x2 x3 / solution ss1 ss2 ss3 ss4; 44 title2 'Multiple Regression with PROC GLM'; 45 run; 46 47 ods html close; 48 ods rtf close; 49 ods PDF close; NOTE: ODS PDF printed 12 pages to C:\EXST 7005\SAS\Example09.PDF. 50 51 run; 52 quit; Generic multiple regression introduction Multiple Regression with PROC GLM The GLM Procedure Number of Observations Read Number of Observations Used 12 12 James P. Geaghan Copyright 2010 Statistical Methods I (EXST 7005) Appendix 9 Page 235 Generic multiple regression introduction Multiple Regression with PROC GLM The GLM Procedure Dependent Variable: Y Sum of Squares 26.18994658 36.72672008 62.91666667 Source Model Error Corrected Total DF 3 8 11 R-Square Coeff Var Root MSE Y Mean 0.416264 46.74817 2.142625 Mean Square 8.72998219 4.59084001 F Value 1.90 Pr > F 0.2078 4.583333 Source X1 X2 X3 DF 1 1 1 Type I SS 23.97762646 0.09683730 2.11548283 Mean Square 23.97762646 0.09683730 2.11548283 F Value 5.22 0.02 0.46 Pr > F 0.0516 0.8881 0.5164 Source X1 X2 X3 DF 1 1 1 Type II SS 22.05273729 0.81916182 2.11548283 Mean Square 22.05273729 0.81916182 2.11548283 F Value 4.80 0.18 0.46 Pr > F 0.0598 0.6838 0.5164 Source X1 X2 X3 DF 1 1 1 Type III SS 22.05273729 0.81916182 2.11548283 Mean Square 22.05273729 0.81916182 2.11548283 F Value 4.80 0.18 0.46 Pr > F 0.0598 0.6838 0.5164 Source X1 X2 X3 DF 1 1 1 Type IV SS 22.05273729 0.81916182 2.11548283 Mean Square 22.05273729 0.81916182 2.11548283 F Value 4.80 0.18 0.46 Pr > F 0.0598 0.6838 0.5164 Parameter Intercept X1 X2 X3 Estimate 1.144541173 0.705779391 0.134827053 -0.186211994 Standard Error 2.57777758 0.32202071 0.31918191 0.27431463 t Value 0.44 2.19 0.42 -0.68 Pr > |t| 0.6688 0.0598 0.6838 0.5164 James P. Geaghan Copyright 2010 ...
View Full Document

This note was uploaded on 12/29/2011 for the course EXST 7005 taught by Professor Geaghan,j during the Fall '08 term at LSU.

Ask a homework question - tutors are online