The SURVEYMEANS Procedure |
Output Data Sets |
PROC SURVEYMEANS uses the Output Delivery System (ODS) to create output data sets. This is a departure from older SAS procedures that provide OUTPUT statements for similar functionality. For more information about ODS, see Chapter 20, Using the Output Delivery System.
For example, to save the "Statistics" table shown in Figure 85.4 in the previous section in an output data set, you use the ODS OUTPUT statement as follows:
title1 'Analysis of Ice Cream Spending'; title2 'Stratified Simple Random Sample Design'; proc surveymeans data=IceCream total=StudentTotals; stratum Grade / list; var Spending Group; weight Weight; ods output Statistics=MyStat; run;
The statement
ods output Statistics=MyStat;
requests that the "Statistics" table that appears in Figure 85.4 be placed in a SAS data set MyStat.
The PRINT procedure displays observations of the data set MyStat:
proc print data=MyStat; run;
Figure 85.5 displays the data set MyStat.
The section ODS Table Names gives the complete list of the tables produced by PROC SURVEYMEANS.
Copyright © 2009 by SAS Institute Inc., Cary, NC, USA. All rights reserved.