x cd /pub/data/eeo2000/Tools; %let pgm=invoke_dosets; filename pgm "&pgm..sas"; /*--Invoke the %doset macro to create observations in the Datasets dataset for this directory. J. Blodgett, OSEDA, Dec., 2003 -- */ title "Job to Invoke doset Macro for Sets in eeo2000, creating eeo2000.datasets"; libname eeo2000 '/pub/data/eeo2000'; %let filetype=eeo2000; *-----Run this step ONLY ONCE------------------------------------------; *----If you need to rerun (start over) then delete the datasets dataset first. doset will not allow initialize mode if the datasets set already exists.---; %doset(mode=initialize, libname=eeo2000,debug=1); *----------------------------------------------------------------------; /*<=========================Comment out===================================== *---------------------Table Group A------------------------------------; *---Define template for the first 7 datasets, the "A" group (based on residence geography)---; %doset(mode=,libname=eeo2000, memname=_template_a, memlabel=, units=, Year=2000, CreatePgm=cnvttbls, Keywords=census 2000 eeo occupation workforce employment race hispanic, Keyvars= SumLev GeoCode State csarea msapmsa ~occvar, Keyfmats=Sumlev eeogeo state csarea msapmsa ~occfmt, Description=%nrbquote(Custom tabulations of the Civilian Labor Force Aggregated by residential geography. ), DataSource=%str(2000 Census - EEO Special Tab Product rel. Dec/2003), SortedBy=SumLev Geocode, UsageNotes=%nrbquote(), SubType=, SetGroup=us, VarSet=, URLMeta=%str(https://mcdc.missouri.edu/applications/uexplore.php?/pub/data/eeo2000/sas_doc), debug=0) *------------------Table 1-----------------------------*; %let occvar=cenocc; %let occfmt=cenocc; %doset(libname=&filetype, memname=ustable1,template=_template_a, memlabel=%nrbquote(472 Census Occ. Categories by Residence down to County Sets), geouniv=United_States, units=US State MSA PMSA CountySet, Description=%nrbquote(+ This is one of the largest non-flow datasets with very detailed occupation data (472 census codes), and 4 levels of geography down to counties of 50,000+ and County Sets. Data for the usual 12 EEO Race/Hispanic categories by Sex.), UsageNotes=%nrbquote(+), SubType=table1, SetGroup=us) ; %doset(libname=&filetype, memname=motable1,template=ustable1, geouniv=Missouri,sortprio=1, units=State CountySet, Keyvars= SumLev GeoCode State csarea &occvar, Keyfmats=Sumlev eeogeo state csarea &occfmt, UsageNotes=%nrbquote(+ , setgroup=mo); *------------------Table 2-----------------------------*; %let occvar=opm; %let occfmt=opmocc; %doset(libname=&filetype, memname=ustable2,template=_template_a, memlabel=%nrbquote(268 OPM Occ. Categories by Residence down to County Sets), geouniv=United_States, units=US State MSAs PMSA CountySet, Description=%nrbquote(+ This is one of the larger non-flow datasets with 268 OPM Federal Workforce occupation groups and the same 4 levels of geography as Table 1. Data for the usual 12 EEO Race/Hispanic categories by Sex.), UsageNotes=%nrbquote(+), SubType=table1, SetGroup=us) ; %doset(libname=&filetype, memname=motable2,template=ustable2, geouniv=Missouri,sortprio=1, units=State CountySet, Keyvars= SumLev GeoCode State csarea &occvar, Keyfmats=Sumlev eeogeo state csarea &occfmt, UsageNotes=%nrbquote(+ , setgroup=mo); *------------------Table 5-----------------------------*; %let occvar=st_loc; %let occfmt=stloc; %doset(libname=&filetype, memname=ustable5,template=_template_a, memlabel=%nrbquote(8 State & Local Govt Occ. Cats by Residence down to County & large place), geouniv=United_States, units=US State MSA PMSA County Place50k, keyvars=SumLev GeoCode State County Place MsaPmsa &occvar, Keyfmats=Sumlev eeogeo state county fplace msapmsa &occfmt, Keyquals= | | | | state, Description=%nrbquote(+ State and Local Job Categories (8) for US, states, counties, metro areas and places of 50,000 or more. Data for the usual 12 EEO Race/Hispanic categories by Sex.), UsageNotes=%nrbquote(+), SubType=table5, SetGroup=us) ; %doset(libname=&filetype, memname=motable5,template=ustable5, geouniv=Missouri,sortprio=1, units=State County Place50k, Keyvars= SumLev GeoCode State County Place &occvar, Keyfmats=Sumlev eeogeo state county fplace &occfmt, Keyquals= | | | | state, UsageNotes=%nrbquote(+ , setgroup=mo); *------------------Table 6-----------------------------*; %let occvar=; %let occfmt=; %doset(libname=&filetype, memname=ustable6,template=_template_a, memlabel=%nrbquote(Younger Age Groups & Ed Attainment for Counties & Places of 50k+), geouniv=United_States, units=County Place50k, Keywords=census 2000 eeo workforce race hispanic age education, keyvars=SumLev GeoCode State County Place &occvar, Keyfmats=Sumlev eeogeo state county fplace &occfmt, Keyquals= | | | | state, Description=%nrbquote(+Younger Age Groups, Educational Attainment, Race/Ethnicity and Sex for all counties and places of 50,000 or more. See Appendix 4.2 for category detail.), UsageNotes=%nrbquote(+), SubType=table6, SetGroup=us) ; %doset(libname=&filetype, memname=motable6,template=ustable6, geouniv=Missouri,sortprio=1, units=County Place50k, Keyvars= SumLev GeoCode State County Place &occvar, Keyfmats=Sumlev eeogeo state county fplace &occfmt, Keyquals= | | | | state, UsageNotes=%nrbquote(+ , setgroup=mo); *------------------Table 7-----------------------------*; %let occvar=; %let occfmt=; %doset(libname=&filetype, memname=ustable7,template=_template_a, memlabel=%nrbquote(Younger Age Groups & Ed Attainment for US, States & Metros), geouniv=United_States, units=US State MSA PMSA, Keywords=census 2000 eeo workforce race hispanic age education, keyvars=SumLev GeoCode State msapmsa &occvar, Keyfmats=Sumlev eeogeo state msapmsa &occfmt, Keyquals=, Description=%nrbquote(+Younger Age Groups, Educational Attainment(6), Race/Ethnicity and Sex for US totals, states and metro areas. See Appendix 4.2 for category detail.), UsageNotes=%nrbquote(+), SubType=table7, SetGroup=us) ; %doset(libname=&filetype, memname=motable7,template=ustable7, geouniv=Missouri,sortprio=1, units=County Place50k, Keyvars= SumLev GeoCode State &occvar, Keyfmats=Sumlev eeogeo state &occfmt, Keyquals=, UsageNotes=%nrbquote(+ , setgroup=mo); *---------------------Table Group B ------------------------------------; *---Define template for tables 8 - 19 datasets, the "B" group (based on workplace / residence geography)---; %doset(mode=,libname=eeo2000, memname=_template_b, memlabel=, units=, Year=2000, CreatePgm=cnvttbls, Keywords=census 2000 eeo occupation workforce employment race hispanic, Keyvars= SumLev GeoCode State csarea msapmsa ~occvar, Keyfmats=Sumlev eeogeo state csarea msapmsa ~occfmt, Description=%nrbquote(Custom tabulations of the Civilian Labor Force Aggregated by residential geography. ), DataSource=%str(2000 Census - EEO Special Tab Product rel. Dec/2003), UsageNotes=%nrbquote(), SubType=, SetGroup=us, VarSet=, URLMeta=%str(https://mcdc.missouri.edu/applications/uexplore.php?/pub/data/eeo2000/sas_doc), debug=0) *------------------Table 8-----------------------------*; %let occvar=occvar; %let occfmt=occfmt; %doset(libname=&filetype, memname=ustable8,template=_template_b, memlabel=%nrbquote(Younger Age Groups & Ed Attainment for US, States & Metros), geouniv=United_States, units=CountyCounty, Keywords=, keyvars= cenocc pow_geo_cty res_geo_cty racehsp qsex, Keyfmats=cenocc eeocnty eeocnty eeorace eeosex , Keyquals=, Description=%nrbquote(+Younger Age Groups, Educational Attainment(6), Race/Ethnicity and Sex for US totals, states and metro areas. See Appendix 4.2 for category detail.), UsageNotes=%nrbquote(+), SubType=ustable8, SetGroup=us) ; %doset(libname=&filetype, memname=motable8,template=ustable8, geouniv=Missouri,sortprio=1, units=CountyCounty, Keyvars = cenocc pow_geo_cty res_geo_cty racehsp qsex, Keyfmats= cenocc eeocnty eeocnty eeorace eeosex, Keyquals=, UsageNotes=%nrbquote(+ , setgroup=mo); ===========================End commented out================================ */ *------------------Table 9-----------------------------*; %let occvar=occvar; %let occfmt=occfmt; %doset(libname=&filetype, memname=ustable9,template=_template_b, memlabel=%nrbquote(Younger Age Groups & Ed Attainment for US, States & Metros), geouniv=United_States, units=CountyCounty, Keywords=, keyvars= opm OccName pow_geo_cty res_geo_cty racehsp qsex, Keyfmats=opmocc opmocc eeocnty eeocnty eeorace eeosex , Keyquals=, Description=%nrbquote(+Younger Age Groups, Educational Attainment(6), Race/Ethnicity and Sex for US totals, states and metro areas. See Appendix 4.2 for category detail.), UsageNotes=%nrbquote(+), SubType=ustable9, SetGroup=us) ; %doset(libname=&filetype, memname=motable9,template=ustable9, geouniv=Missouri,sortprio=1, units=CountyCounty, Keyvars = opm OccName pow_geo_cty res_geo_cty racehsp qsex, Keyfmats= opmocc opmocc eeocnty eeocnty eeorace eeosex, Keyquals=, UsageNotes=%nrbquote(+ , setgroup=mo); *-------------------Alternative view datasets (radical restructurings)-------------------*; %doset(libname=&filetype, memname=altustable1,template=ustable1, memlabel=%str(One-Obs-Per-Cell Alternate view of ustable1 data), units=t1_table_cells, sortprio=4, keyvars=SumLev GeoCode State cenocc race hispanic rhtype, keyfmats=sumlev eeogeo state cenocc | | | , description=%nrbquote(Experimental dataset in which we have replaced the 24-cell table of the ustable1 dataset with 1 obs per non-zero cell per geography/occupation code. Makes for a very long skinny dataset, one that may be easier to use for some.), UsageNotes=%nrbquote(), subtype=altview1, setgroup=us, debug=0); %doset(libname=&filetype, memname=altustable23,template=altustable1, memlabel=%str(One-Obs-Per-Cell Alternate view of table23 data), units=t23_table_cells, sortprio=4, keyvars=sumlev geocode workstate workcounty cenocc Industry rhtype race hispanic , keyfmats=sumlev eeogeo state eeocnty cenocc eeo_ind , description=%nrbquote(Detailed Occs x Industry x Race/Hisp x Sex-US, Cos & Plcs 100K+), UsageNotes=%nrbquote(), subtype=altview1, setgroup=us, debug=0); x cd /pub/data/eeo2000/Tools; %let pgm=invoke_dosets; filename pgm "&pgm..sas"; /*--Invoke the %doset macro to create observations in the Datasets dataset for this directory. J. Blodgett, OSEDA, Dec., 2003 -- */ title "Job to Invoke doset Macro for Sets in eeo2000, creating eeo2000.datasets"; libname eeo2000 '/pub/data/eeo2000'; %let filetype=eeo2000; *-----Run this step ONLY ONCE------------------------------------------; *----If you need to rerun (start over) then delete the datasets dataset first. doset will not allow initialize mode if the datasets set already exists.---; %doset(mode=initialize, libname=eeo2000,debug=1); *----------------------------------------------------------------------; proc sort data=eeo2000.datasets out=bysortprio; by sortprio; run; proc print data=bysortprio; by libname notsorted libpath ; id memname; var SortPrio SetGroup SubType VarSet URLmeta GeoUniv years ; title2 'Listing of Selected Fields from eeo2000.datasets (Sorted by SortPrio)'; run ; proc datasets library=eeo2000 nolist; modify datasets; index delete dataset memname; index create dataset=(libname memname) / unique; index create memname; quit; options mprint msglevel=i; %gendshtm(libname=eeo2000,debug=1,runprocc=1); %include sascode(notify);