Hi,
I am using longitudinal data collected at unequal spaced intervals (1989, 1991, 1993, 1997, 2000....). I'm trying to figure out the individuals who participated in t0 survey but did not participate in t0+1 survey. I have a individual id for each person to check participation in each wave. The code below is giving me the number of people in each wave as opposed to those who dropped out. I;m not sure what I'm missing.
xtset idind year
gen leave=0 if idind==f.idind
replace leave=1 if idind<. & f.idind==.
replace leave=. if year==2015
label var leave "=1 if R did not participate in survey in t+1"
tab year leave
tab year, sum(leave)
tab year if esample==1, sum(leave)
I am using longitudinal data collected at unequal spaced intervals (1989, 1991, 1993, 1997, 2000....). I'm trying to figure out the individuals who participated in t0 survey but did not participate in t0+1 survey. I have a individual id for each person to check participation in each wave. The code below is giving me the number of people in each wave as opposed to those who dropped out. I;m not sure what I'm missing.
xtset idind year
gen leave=0 if idind==f.idind
replace leave=1 if idind<. & f.idind==.
replace leave=. if year==2015
label var leave "=1 if R did not participate in survey in t+1"
tab year leave
tab year, sum(leave)
tab year if esample==1, sum(leave)

Comment