post_se and pre_se can only occur once for each pid because the data was selected on one time self-employment. The number I want to find is the average wage growth starting from the year before until the year after slef-employment. The formula I wanted to use is (mean(post_se_pay)-mean(pre_se_pay)/number of years between pre_se and post_se. Now I dont really know how I can get this average number of years. This is what I thought: by pid (wave), sort: egen years_between = wave(post_se)-wave(pre_se) but that obviously doesnt work and I dont know how to account for the cases when there is no pre_se for example. I am really sorry to depend on you all the time but I dont find any information regarding my problem anywhere...
-
Login or Register
- Log in with
Comment