Procedure features: |
PROC
REPORT statement options:
|
COLUMN statement:
|
specifying statistics for stacked variables | |
DEFINE statement options:
|
|
Data set: |
GROCERY
|
Formats: |
$MGRFMT.
|
The report in this example displays six statistics for the sales
for
each manager's store. The output is too wide to fit all the columns on one
page, so three of the statistics appear on the second page of the report.
In order to make it easy to associate the statistics on the second page with
their group, the report repeats the values of Manager and Sector on every
page of the report.
|
libname proclib 'SAS-library'; |
|
options nodate pageno=1 linesize=80 pagesize=60
fmtsearch=(proclib); |
|
proc report data=grocery nowd headline headskip
ls=66 ps=18; |
|
column sector manager (Sum Min Max Range Mean Std),sales; |
|
define manager / group format=$mgrfmt. id;
define sector / group format=$sctrfmt.;
define sales / format=dollar11.2 ; |
|
title 'Sales Statistics for All Sectors';
run; |
Sales Statistics for All Sectors 1
Sum Min Max
Sector Manager Sales Sales Sales
---------------------------------------------------------
Northeast Alomar $786.00 $86.00 $420.00
Andrews $1,045.00 $125.00 $420.00
Northwest Brown $598.00 $45.00 $250.00
Pelfrey $746.00 $45.00 $420.00
Reveiz $1,110.00 $30.00 $600.00
Southeast Jones $630.00 $40.00 $300.00
Smith $350.00 $50.00 $120.00
Southwest Adams $695.00 $40.00 $350.00
Taylor $353.00 $50.00 $130.00
Sales Statistics for All Sectors 2
Range Mean Std
Sector Manager Sales Sales Sales
---------------------------------------------------------
Northeast Alomar $334.00 $196.50 $156.57
Andrews $295.00 $261.25 $127.83
Northwest Brown $205.00 $149.50 $105.44
Pelfrey $375.00 $186.50 $170.39
Reveiz $570.00 $277.50 $278.61
Southeast Jones $260.00 $157.50 $123.39
Smith $70.00 $87.50 $29.86
Southwest Adams $310.00 $173.75 $141.86
Taylor $80.00 $88.25 $42.65
Copyright © 2010 by SAS Institute Inc., Cary, NC, USA. All rights reserved.