OPTIONS LINESIZE=72 PAGESIZE=55 NODATE NONUMBER NOCENTER; ******************************************************************; *** Program Name Date Disk Label Programmer ; TITLE1 "Source: PRT1.SAS 9/29/98 Ed Stanek "; * DESCRIPTION: Read in ICU Data to Illustrate PROC PRINT ; ******************************************************************; DATA icu; INFILE CARDS FIRSTOBS=11; INPUT icuid sta age sex race ser can crn inf cpr sys hra pre typ fra po2 ph pco bic cre loc; CARDS; The data in this file are those of Appendix 2 from Hosmer, D.W. and Lemeshow, S. (1989) Applied Logistic Regression, John Wiley and Sons, New York. They are reproduced here with the permission of the publisher and as such are copyright. R S A S A S C C I C S H P T F P P B C L I T G E C E A R N P Y R R Y R O P C I R O D A E X E R N N F R S A E P A 2 H O C E C 8 0 27 1 1 0 0 0 1 0 142 88 0 1 0 0 0 0 0 0 0 12 0 59 0 1 0 0 0 0 0 112 80 1 1 0 0 0 0 0 0 0 14 0 77 0 1 1 0 0 0 0 100 70 0 0 0 0 0 0 0 0 0 28 0 54 0 1 0 0 0 1 0 142 103 0 1 1 0 0 0 0 0 0 32 0 87 1 1 1 0 0 1 0 110 154 1 1 0 0 0 0 0 0 0 38 0 69 0 1 0 0 0 1 0 110 132 0 1 0 1 0 0 1 0 0 40 0 63 0 1 1 0 0 0 0 104 66 0 0 0 0 0 0 0 0 0 41 0 30 1 1 0 0 0 0 0 144 110 0 1 0 0 0 0 0 0 0 42 0 35 0 2 0 0 0 0 0 108 60 0 1 0 0 0 0 0 0 0 50 0 70 1 1 1 1 0 0 0 138 103 0 0 0 0 0 0 0 0 0 51 0 55 1 1 1 0 0 1 0 188 86 1 0 0 0 0 0 0 0 0 53 0 48 0 2 1 1 0 0 0 162 100 0 0 0 0 0 0 0 0 0 58 0 66 1 1 1 0 0 0 0 160 80 1 0 0 0 0 0 0 0 0 61 0 61 1 1 0 0 1 0 0 174 99 0 1 0 0 1 0 1 1 0 73 0 66 0 1 0 0 0 0 0 206 90 0 1 0 0 0 0 0 1 0 75 0 52 0 1 1 0 0 1 0 150 71 1 0 0 0 0 0 0 0 0 82 0 55 0 1 1 0 0 1 0 140 116 0 0 0 0 0 0 0 0 0 84 0 59 0 1 0 0 0 1 0 48 39 0 1 0 1 0 1 1 0 2 92 0 63 0 1 0 0 0 0 0 132 128 1 1 0 0 0 0 0 0 0 96 0 72 0 1 1 0 0 0 0 120 80 1 0 0 0 0 0 0 0 0 98 0 60 0 1 0 0 0 1 1 114 110 0 1 0 0 0 0 0 0 0 100 0 78 0 1 1 0 0 0 0 180 75 0 0 0 0 0 0 0 0 0 ; PROC PRINT; TITLE2 "Table 1. Basic Data for Illustration of PROC PRINT"; RUN; *****************************************************************; *** Detailed PROC PRINT statements illustrating basic features *; *****************************************************************; PROC PRINT; TITLE2 "Table 1a. Printing All Variables"; PROC PRINT; VAR icuid age sex race; TITLE2 "Table 1b. Printing a Subset of Variables"; PROC PRINT DATA=icu (OBS=5); TITLE2 "Table 1c. Printing the first several records"; PROC PRINT; WHERE sex=1; VAR icuid age race sex; TITLE2 "Table 1d. Printing records conditionally on subjects with sex=1"; PROC PRINT NOOBS; VAR icuid age; TITLE2 "Table 1e. Printing records with OBS column suppressed"; PROC PRINT; ID icuid; VAR age race; TITLE2 "Table 1f. Printing records with an ID variable"; RUN;