x cd /pub/data/pl942010/Tools; %let pgm=agg_popbysumlev; filename pgm "&pgm..sas"; *--You can delete this line-; libname pl942010 '/pub/data/pl942010'; *--This is the directory where the output data sets are saved--; libname pl94 (pl942010); *--alternate name---; ods html file ="&pgm..html"; proc means data=pl94.mosums n sum min max mean median maxdec=0; class sumlev; var totpop tothus; format sumlev $slvlwc.; run;