Selecting Statistics

The default statistics that the MEANS procedure produces are not always the ones that you need. You might prefer to limit output to the mean of the values. Or you might need to compute a different statistic, such as the median or range of the values.
To specify statistics, include statistic keywords as options in the PROC MEANS statement. When you specify a statistic in the PROC MEANS statement, default statistics are not produced. For example, to determine the median and range of Perm.Survey numeric values, add the MEDIAN and RANGE keywords as options.
proc means data=perm.survey median range; 
run;
Figure 9.2 MEANS Procedure Output Displaying Median and Range
Use the following keywords with PROC MEANS to compute ...

Get SAS Certification Prep Guide, 4th Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.