Scientific Data Documentation
STF1 - SAS Code and Analysis
DSN: CC36.CENSUS.STF1.SASCODE INTRODUCTION This diskette contains programs which create SAS datasets from a 1990 U.S. Census STF1 raw file and create formatted reports of the STF1 census tables. Program CNVTSTF1 creates a SAS dataset containing full STF1 records. This program calls macro STF901C, which calls macro ATTR901. These macros must be located at the path specified in filename 'storage'. The subsetting 'if' statement ('if sumlev in. . .') should be changed to reflect the subset desired--or omitted to pull all records. Please note that the STF901C macro included here has been slightly modified--see below. The macros are in subdirectory MACLIB on this diskette. To create report files containing STF1 tables for any record(s), run program STF1RPTS. Be sure that the 96 report programs, or the desired subset of them, are at the location referred to in filename 'storage'. Edit the subsetting 'if' statement at the beginning of the program to select the record(s) desired. Delete or comment out any tables which are not needed in the report. If all tables are written, this report is 42 pages (80K) per STF3A record. The 96 report modules are located in subdirectories S1RPT1 through S1RPT4 on this diskette. They are spread across 4 directories because, under MS-DOS, this is too many files for efficient retrieval from one subdirectory. I recommend dumping all the report modules into one subdirectory on a hard disk. Macros STF901C and ATTR901 were created by John Blodgett at the University of Missouri-St. Louis Urban Information Center. I have modified STF901C so that ID variable names match the Census Bureau Technical Documentation. (John Blodgett's names were more descriptive, but my users use the tech document.) The labels for each line of a table come originally from the variable labels in macro ATTR901. Some of the tables have been prettied up by editing, but most have not. Since variable labels are limited to 40 characters, sometimes the lower qualifiers do not appear in a label-- leaving a label which could be misinterpreted. One solution to this problem is to work with the Census Bureau Technical Documentation in hand. A more laborious solution is to edit the tables you care about. There's a tradeoff: the better the tables look to the eye, the more paper/bytes they take--a concern when each full record prints 42 pages. Not so much a concern if the reports will remain online. This code was written and used on a Sun Sparcstation II running SAS release 6.0.7. However, it should be appropriate for any release of SAS. It was run against 1990 U.S. Census STF1A raw data. However, I believe the file layout for STF1B is identical, so it should work with that data also. I cannot provide support for this code--it is offered "as is". However, I would appreciate hearing about any bugs or typos in it. ---------------------------------------------------------------- Mary Conklin Gomberg Center for Health Administration Studies University of Chicago Internet: mary@chas.uchicago.edu 969 E. 60th St. Phone: 312-702-7753 Chicago, IL 60637 Fax: 312-702-7222 ---------------------------------------------------------------- SAS CODE AND ANALYSIS SAS code is available in CC37.STF1.SASCODE.