Features: |
|
Other features: |
FORMAT procedure |
data jobclass; input Gender Occupation @@; datalines; 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 3 1 3 1 3 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 2 1 2 1 3 1 3 1 4 1 4 1 4 1 4 1 4 1 4 1 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 4 1 4 1 4 1 1 1 3 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 2 2 2 2 2 2 2 2 2 2 3 2 3 2 3 2 4 2 4 2 4 2 4 2 4 2 4 2 1 2 3 2 3 2 3 2 3 2 3 2 4 2 4 2 4 2 4 2 4 2 1 2 1 2 1 2 1 2 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 2 3 2 4 2 4 2 4 2 1 2 1 2 1 2 1 2 1 2 2 2 2 2 2 2 3 2 3 2 3 2 3 2 4 ;
proc format; value gendfmt 1='Female' 2='Male' other='*** Data Entry Error ***'; value occupfmt 1='Technical' 2='Manager/Supervisor' 3='Clerical' 4='Administrative' other='*** Data Entry Error ***'; run;
proc tabulate data=jobclass format=8.2;
class gender occupation;
table (occupation='Job Class' all='All Jobs') *(n='Number of employees'*f=9. pctn<gender all>='Percent of row total' pctn<occupation all>='Percent of column total' pctn='Percent of total'),
gender='Gender' all='All Employees'/ rts=50;
format gender gendfmt. occupation occupfmt.;
title 'Gender Distribution'; title2 'within Job Classes'; run;
data jobclass; input Gender Occupation @@; datalines; 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 3 1 3 1 3 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 2 1 2 1 3 1 3 1 4 1 4 1 4 1 4 1 4 1 4 1 1 1 1 1 1 1 1 1 1 1 2 1 2 1 2 1 2 1 2 1 2 1 2 1 3 1 3 1 3 1 3 1 4 1 4 1 4 1 4 1 4 1 1 1 3 2 1 2 1 2 1 2 1 2 1 2 1 2 1 2 2 2 2 2 2 2 2 2 2 2 3 2 3 2 3 2 4 2 4 2 4 2 4 2 4 2 4 2 1 2 3 2 3 2 3 2 3 2 3 2 4 2 4 2 4 2 4 2 4 2 1 2 1 2 1 2 1 2 1 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 3 2 3 2 4 2 4 2 4 2 1 2 1 2 1 2 1 2 1 2 2 2 2 2 2 2 3 2 3 2 3 2 3 2 4 ;
proc format; value gendfmt 1='Female' 2='Male' other='*** Data Entry Error ***'; value occupfmt 1='Technical' 2='Manager/Supervisor' 3='Clerical' 4='Administrative' other='*** Data Entry Error ***'; run;
table (occupation='Job Class' all='All Jobs') *(n='Number of employees'*f=9. pctn<gender all>='Percent of row total' pctn<occupation all>='Percent of column total' pctn='Percent of total'),
female, technical
or all,
clerical
female, technical
is the
sum of all frequency counts for all categories in this subtable for
which the value of Occupation is technical
.
There are two such categories: female, technical
and male,
technical
. The corresponding frequency counts are 16
and 18. Therefore, the denominator for this category is 16+18, or
34.
all, female
is the sum of
the frequency counts for all, female
and all,
male
. The corresponding frequency counts are 61 and 62.
Therefore, the denominator for cells in this subtable is 61+62, or
123.
clerical, all
is the frequency
count for that category, 28.
manager/supervisor, male
is
the sum of all frequency counts for all categories in this subtable
for which the value of Gender is male
. There
are four such categories: technical, male
; manager/supervisor,
male
; clerical, male
; and administrative,
male
. The corresponding frequency counts are 18, 15,
14, and 15. Therefore, the denominator for this category is 18+15+14+15,
or 62.
all, female
is the frequency
count for that category, 61.
technical, all
is the sum
of the frequency counts for technical, all
; manager/supervisor,
all
; clerical, all
; and administrative,
all
. The corresponding frequency counts are 34, 35, 28,
and 26. Therefore, the denominator for this category is 34+35+28+26,
or 123.