log using match_single_year, text replace *by Jean Roth, 2003-01-30, jroth@nber.org *This program takes a minute or two to run per year set mem 750m set more 1 program define match2 use /homes/data/morg/match/ saveold /home/data/morg/match/match`1'4.dta, replace drop if mminsamp==4 drop mminsamp if ( `1' == 1984 ) { sort `sort_stem' `sortnf' } if ( `1' == 1994 ) { sort `sort_stem' `sortf' } saveold /home/data/morg/match/match`1'8.dta,replace clear use /home/data/morg/match/match`1'4.dta drop if mminsamp==8 drop mminsamp saveold /home/data/morg/match/match`1'4.dta,replace clear ! rm -f match.dct /tmp/match.raw end * Each block of commands does one year of the data. The data must be * decompressed, and possibly have dashes converted to blanks. * Then a dictionary for the particular year is prepared by * concatenating a one line header (with the file name) to a generic * dictionary body that covers several years of data that used the * same format. *Lastly, the data is read, modified, summarized and saved. match2 1979 79 79_83 match2 1980 80 79_83 match2 1981 81 79_83 match2 1982 82 79_83 match2 1983 83 79_83 match2 1984 84 84_88 match2 1985 85 84_88 match2 1986 86 84_88 match2 1987 87 84_88 match2 1988 88 84_88 match2 1989 89 89_93 match2 1990 90 89_93 match2 1991 91 89_93 match2 1992 92 89_93 match2 1993 93 89_93 match2 1994 94 94_97 match2 1995 95 94_97 match2 1996 96 94_97 match2 1997 97 94_97 match2 1998 98 98 match2 1999 99 98 match2 2000 00 98 match2 2001 01 98 match2 2002 02 98 match2 2003 02 98