29.12.2013 Views

Base SAS 9.1.3 Procedures Guide - Acsu Buffalo

Base SAS 9.1.3 Procedures Guide - Acsu Buffalo

Base SAS 9.1.3 Procedures Guide - Acsu Buffalo

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

The TABULATE Procedure 4 Program 1283<br />

A Closer Look<br />

Here are the percentage sum statistic calculations used to produce the output for the<br />

Blue Team in Classroom A:<br />

COLPCTSUM=31/91*100=34%<br />

ROWPCTSUM=31/67*100=46%<br />

REPPCTSUM=31/204*100=15%<br />

Similar calculations were used to produce the output for the remaining teams and<br />

classrooms.<br />

Example 13: Using Denominator Definitions to Display Basic Frequency<br />

Counts and Percentages<br />

Procedure features:<br />

TABLE statement:<br />

ALL class variable<br />

denominator definitions (angle bracket operators)<br />

N statistic<br />

PCTN statistic<br />

Other features:<br />

FORMAT procedure<br />

Crosstabulation tables (also called contingency tables and stub-and-banner reports)<br />

show combined frequency distributions for two or more variables. This table shows<br />

frequency counts for females and males within each of four job classes. The table also<br />

shows the percentage that each frequency count represents of<br />

3 the total women and men in that job class (row percentage)<br />

3 the total for that gender in all job classes (column percentage)<br />

3 the total for all employees.<br />

Program<br />

Set the <strong>SAS</strong> system options. The NODATE option suppresses the display of the date and time<br />

in the output. PAGENO= specifies the starting page number. LINESIZE= specifies the output<br />

line length, and PAGESIZE= specifies the number of lines on an output page.<br />

options nodate pageno=1 linesize=80 pagesize=60;<br />

Create the JOBCLASS data set. JOBCLASS contains encoded information about the gender<br />

and job class of employees at a fictitious company.<br />

data jobclass;<br />

input Gender Occupation @@;

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!