![]() Chapter Contents |
![]() Previous |
![]() Next |
| SAS/GRAPH Software: Reference |
/* assign the destination for the output */
filename out 'external-file.gif';
/* set the graphics environment */
goptions reset=global gunit=pct border
cback=ligr ctext=black
colors=(blue green red) ftext=swissb
ftitle=swissb htitle=6 htext=5;
/* assign graphics options for the animation */
goptions display
dev=gifanim
gsfname=out
gsfmode=replace
iteration=0
delay=200;
/* create data set REGSALES */
data regsales;
length Region State $ 8;
format Sales dollar8.;
input Region State Sales;
datalines;
West CA 13636
West OR 18988
West WA 14523
Central IL 18038
Central IN 13611
Central OH 11084
Central MI 19660
South FL 14541
South GA 19022
;
/* sort the data set */
proc sort data=regsales out=regsales;
by region;
run;
/* generate the charts */
title1 'Company Sales';
proc gchart data=regsales;
vbar state / sumvar=sales
patternid=by;
by region;
run;
quit;
/* end the animation */
data _null_;
file out recfm=n mod;
put '3B'x;
run;
goptions reset=all;
![]() Chapter Contents |
![]() Previous |
![]() Next |
![]() Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.