x cd /pub/data/stf902/Tools; %let pgm=mostcopb5; filename pgm "&pgm..sas"; *---Create a data set with one obs per geography (state and county) / chariter (race/hispanic) from the 1990 stf2, file b, Missouri, Table PB5: Sex(2) by Age(103). We keep all available chariters and geocomps. Coded by John Blodgett, OSEDA, Oct. 2001. ---*; title "Create stf902.&pgm : Detailed Age by Sex by Race by Hispanic origin for Missouri State and County"; libname user "/tmp/storage/john"; *<---special work-like directory--; libname stf902 '/pub/data/stf902'; /*<=========================Comment out===================================== signon oseda; *<--required to use the server= option to access data on another AIX box-; libname stf902b '/mscdc/data/stf902/b' server=oseda access=readonly; data stf902.&pgm (label='1990 STF2, File B, Table PB5 for Missouri State & County (no geocomps)' compress=yes); length SumLev $3; set stf902b.mobtbls (keep=recno--fipco cnty msacmsa intptlat intptlng areasqmi arealand areawat pb1i1 pb5i1-pb5i206); where slvl in ('040','050') and geocomp='00'; SumLev=slvl; label pb5i1='Total Pop 1990'; run; proc sort data=stf902.&pgm; by sumlev county chariter; run; ===========================End commented out================================ */ proc tabulate data = stf902.&pgm ; class sumlev chariter msacmsa; var pb1i1; format chariter $charitr.; table sumlev*chariter , pb1i1*(N="Nareas" sum='Sum'*f=comma13.); title2 'Tabulate Report'; run; proc contents data=stf902.&pgm position; title2 'Contents Report'; run;