ARCHIVED: In SAS, how can I find summary statistics such as the median, skewness, kurtosis, and quantiles?
In SAS, you can use the
SUMMARY procedures to obtain summary statistics such as
the median, skewness, and kurtosis. The
procedure provides a variety of summary statistics for each variable
listed in the
VAR statement without special options. If
VAR statement is omitted,
UNIVARIATE will return statistics for all variables in the data
set, for example:
DATA sample; INPUT id 1-2 school 3-4 wages 5-6; DATALINES; 011243 021633 030834 041448 051642 RUN; PROC UNIVARIATE; VAR school wages; RUN;
SUMMARY procedures also
provide similar statistics, although specific statistics to be
displayed should be listed as options.
MEANS procedures, the
VAR statement may not
be omitted in the
SUMMARY procedure. The following
examples of the
produce exactly the same statistics:
PROC MEANS MEAN STD MEDIAN KURTOSIS SKEWNESS MEDIAN Q1 Q3; VAR school wages; RUN;
PROC SUMMARY PRINT MEAN STD MEDIAN KURTOSIS SKEWNESS MEDIAN Q1 Q3; VAR school wages; RUN;
If you have questions about using statistical and mathematical software at Indiana University, contact Research Analytics. Research Analytics is located on the IU Bloomington campus at Woodburn Hall 200; staff are available for consultation Monday-Friday 9am-noon and by appointment.
This is document afrc in the Knowledge Base.
Last modified on 2015-06-29 00:00:00.
- Fill out this form to submit your issue to the UITS Support Center.
- Please note that you must be affiliated with Indiana University to receive support.
- All fields are required.