Chapter Contents |
Previous |
Next |
The UNIVARIATE Procedure |
Procedure features: |
| |||||||||
Other features: |
| |||||||||
Data set: | STATEPOP |
Program |
options nodate pageno=1 linesize=120 pagesize=80;
proc format; value Regnfmt 1='Northeast' D 2='South' 3='Midwest' 4='West'; run; |
proc sort data=metropop; by region decade; run; |
proc univariate data=metropop nextrobs=0 plots plotsize=20 ; |
var populationcount; |
by region decade; |
output out=censtat sum=PopulationTotal mean=PopulationMean std=PopulationStdDeviation pctlpts=50 to 100 by 25 pctlpre=Pop_ ; |
format region regnfmt.; title 'United States Census of Population and Housing'; run; |
proc print data=censtat; title1 'Statistics for Census Data by Decade and Region'; title2 'Output Dataset From PROC UNIVARIATE'; run; |
Output |
The CENSTAT data set includes the BY variables Region and Decade and contains eight observation, one for each BY group. | |
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.