Econ 46 - Dartmouth College | Home

sort id. merge id using returns.dta This will sort on the variable called id and then merge in the data from returns using id as the key ... tabulate exch, generate exdum (you'll get 3 dummy variables exdum1, exdum2, exdum3) ... Stata Notes: In order to create a lagged variable, we can use explicit subscripting. Thus, to create a lag of x, type ... ................
................