Skip to Main Content
PROC TABULATE by Example, Second Edition
book

PROC TABULATE by Example, Second Edition

by Lauren Haworth Lake, Julie McKnight
May 2015
Intermediate to advanced content levelIntermediate to advanced
348 pages
11h 31m
English
SAS Institute
Content preview from PROC TABULATE by Example, Second Edition

Percentages for Three-Dimensional Tables

Using the PCTN Statistic

It is possible to add percentages to three-dimensional tables. It’s not difficult to write the code to create three-dimensional percentages. The challenge is in understanding what the resulting tables are showing. Percentages can be rather confusing across three-dimensional tables because you cannot always see how they add up when looking at a single page.
For our example, we will use the following code:
PROC TABULATE DATA=TEMP;
   CLASS SAT CTRY GENDER;
   TABLE SAT ALL, CTRY ALL, (GENDER ALL)*N;
RUN;
This code produces a table with a page for each level of satisfaction plus a totals page. Each page shows country by gender with totals for the rows and columns. For this example, we ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

SAS 9.4 Language Reference, 6th Edition

SAS 9.4 Language Reference, 6th Edition

SAS Institute

Publisher Resources

ISBN: 9781607649908