Quantile Statistics Examples

Medians

By default, PROC TABULATE computes the median using the same methodology as PROC UNIVARIATE. However, this method uses a lot of resources. If you are working with very large data sets and computer resources are an issue, you might want to use an alternate computational method.
The QMETHOD= option lets you select one of two computational methods for all quantile statistics. The default is QMETHOD=OS. The more efficient option is QMETHOD=HIST or QMETHOD=P2, both of which use a different algorithm to approximate the median.
To see how this option affects the results, we can compare the output created by using the default median and the output created by using the code with the addition of the QMETHOD=HIST ...

Get PROC TABULATE by Example, Second 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.