* This do file creates the attrition regressions in Tables 6 and 7. * cd C:\Users\schechter\Documents\Yating\StabilityPaper\JDE_Data clear use Stability_JDE_data log using attrit, text replace replace totinc=totinc/1000 replace totinc_07=totinc_07/1000 xi i.comp **Test for sample selection ******** 2002 - Table 6 ************* *** 2002 survey and 2007 survey * 214 people answered the 2002 survey. * Answered survey in 2002 and 2007, 123 obs: gen stays2s7=c26a!=. & survey0709!=0 &c100c_07!=.& d_07==1 & samepers==1 | (survey0207==1 & survey0709!=0) * Answered survey in 2002 but attrited for 2007 survey, 91 obs foreach x in totinc lntotinc famsz conquiensex conquieneda conquienedu c26b { *(1)answered survey in 2002 and in 2007 sum `x' if stays2s7==1 *(2)answered survey in 2002 but not in 2007 sum `x' if c26a!=. & survey0709!=0 & stays2s7==0 * Regressions comparing (1) and (2) reg `x' stays2s7 if c26a!=. & survey0709!=0, robust quietly reg `x' stays2s7 if c26a!=. & survey0709!=0, cluster(comp) bootwildct stays2s7 if c26a!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) reg `x' stays2s7 _I* if c26a!=. & survey0709!=0, robust quietly reg `x' stays2s7 _I* if c26a!=. & survey0709!=0, cluster(comp) bootwildct stays2s7 _I* if c26a!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) } ***** 2002 survey and 2010 participate * 214 total, of whom 39 participated in 2010 and 175 did not. * Answered survey in 2002 and 2010, 39 obs gen stays2s10=c26a!=. &c11b_10!=.& (d_07==1&samepers==1&survey0709!=0 | (survey0207==1 & survey0709!=0)) * Answered survey in 2002 but attrited for 2010, 175 obs: foreach x in totinc lntotinc famsz conquiensex conquieneda conquienedu c26b { *(5)answered survey in 2002 and in 2010 sum `x' if stays2s10==1 *(6)answered survey in 2002 but not in 2010 sum `x' if c26a!=. & survey0709!=0 & stays2s10==0 * Regressions comparing (5) and (6) reg `x' stays2s10 if c26a!=. & survey0709!=0, robust quietly reg `x' stays2s10 if c26a!=. & survey0709!=0, cluster(comp) bootwildct stays2s10 if c26a!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) reg `x' stays2s10 _I* if c26a!=. & survey0709!=0, robust quietly reg `x' stays2s10 _I* if c26a!=. & survey0709!=0, cluster(comp) bootwildct stays2s10 _I* if c26a!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) } ***** 2002 game and 2007 game * 188 total of whom 103 participated in 2007 and 85 did not. * Played game in 2002 and 2007, 103 obs gen stayg2g7=condorma!=. & survey0709!=0 & sent_anon_07!=. & d_07==1 & conquienpol_07==jugador_07 * Played game in 2002 but attrited for 2007, 85 obs: foreach x in totinc lntotinc famsz jugadorsex jugadoreda jugadoredu apuesta condorma c26b { *(9) played game in 2002 and in 2007 sum `x' if stayg2g7==1 *(10) played game in 2002 but not in 2007 sum `x' if condorma!=. & survey0709!=0 & stayg2g7==0 * Regressions comparing (9) and (10) reg `x' stayg2g7 if condorma!=. & survey0709!=0, robust quietly reg `x' stayg2g7 if condorma!=. & survey0709!=0, cluster(comp) bootwildct stayg2g7 if condorma!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) reg `x' stayg2g7 _I* if condorma!=. & survey0709!=0, robust quietly reg `x' stayg2g7 _I* if condorma!=. & survey0709!=0, cluster(comp) bootwildct stayg2g7 _I* if condorma!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) } ***** 2002 game and 2010 game * 188 total of whom 43 participated in 2010 and 145 did not. * Played game in 2002 and 2010, 43 obs gen stayg2g10=condorma!=. & survey0709!=0 &c11b_10!=. &d_07==1 * Played game in 2002 but attrited for 2010, 145 obs: foreach x in totinc lntotinc famsz jugadorsex jugadoreda jugadoredu apuesta condorma c26b { *(13) played game in 2002 and in 2010 sum `x' if stayg2g10==1 *(14) played game in 2002 but not in 2010 sum `x' if condorma!=. & survey0709!=0 & stayg2g10==0 * Regressions comparing (13) and (14) reg `x' stayg2g10 if condorma!=. & survey0709!=0, robust quietly reg `x' stayg2g10 if condorma!=. & survey0709!=0, cluster(comp) bootwildct stayg2g10 if condorma!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) reg `x' stayg2g10 _I* if condorma!=. & survey0709!=0, robust quietly reg `x' stayg2g10 _I* if condorma!=. & survey0709!=0, cluster(comp) bootwildct stayg2g10 _I* if condorma!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) } ******** 2007 - Table 7 ************* ***** 2007 survey and 2009 participate * 449 total, of whom 49 participated in 2009 and 400 did not. * Answered survey in 2007 and 2009, 49 obs gen stays7s9 = survey0709==1 * Answered survey in 2007 but attrited for 2009, 400 obs: foreach x in totinc_07 lntotinc_07 famsz_07 conquienpolsexo_07 conquienpoledad_07 conquienpoledu_07 risk1_07 time_07 c100b_07 { *(1) answered survey in 2007 and in 2009 sum `x' if stays7s9==1 *(2) answered survey in 2007 but not in 2009 sum `x' if c100c_07!=. & survey0709!=0 & stays7s9==0 * Regressions comparing (1) and (2) reg `x' stays7s9 if c100c_07!=. & survey0709!=0, robust reg `x' stays7s9 _I* if c100c_07!=. & survey0709!=0, robust } ***** 2007 survey and 2010 participate * 449 total, of whom 119 participated in 2010 and 330 did not. * Answered survey in 2007 and 2010, 119 obs gen stays7s10 =c100c_07!=.& c15a_10!=.&survey0709!=0 * Answered survey in 2007 but attrited for 2010, 330 obs: foreach x in totinc_07 lntotinc_07 famsz_07 conquienpolsexo_07 conquienpoledad_07 conquienpoledu_07 risk1_07 time_07 c100b_07 { *(5) answered survey in 2007 and in 2010 sum `x' if stays7s10==1 *(6) answered survey in 2007 but not in 2010 sum `x' if c100c_07!=. & survey0709!=0 & stays7s10==0 * Regressions comparing (5) and (6) reg `x' stays7s10 if c100c_07!=. & survey0709!=0, robust quietly reg `x' stays7s10 if c100c_07!=. & survey0709!=0, cluster(comp) bootwildct stays7s10 if c100c_07!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) reg `x' stays7s10 _I* if c100c_07!=. & survey0709!=0, robust quietly reg `x' stays7s10 _I* if c100c_07!=. & survey0709!=0, cluster(comp) bootwildct stays7s10 _I* if c100c_07!=. & survey0709!=0, hypothesis(0) bootreps(10000) numvars(1) } ***** 2007 game and 2009 participate * 371 total, of whom 41 participated in 2009 and 330 did not. * Played game in 2007 and 2009, 41 obs gen stayg7g9 = game0709==1 * Played game in 2007 but attrited for 2009, 330 obs: foreach x in totinc_07 lntotinc_07 famsz_07 jug_sexo_07 jug_edad_07 jug_educ_07 risk1_07 time_07 sent_anon_07 c100b_07 { *(9) played game in 2007 and in 2009 sum `x' if stayg7g9==1 *(10) played game in 2007 but not in 2009 sum `x' if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508) & stayg7g9==0 * Regressions comparing (9) and (10) reg `x' stayg7g9 if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508), robust reg `x' stayg7g9 _I* if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508), robust } ***** 2007 game and 2010 participate * 371 total, of whom 81 participated in 2010 and 290 did not. * Played game in 2007 and 2010, 81 obs gen stayg7g10 = sent_anon_07!=. & c11b_10!=.&conquienpol_07==jugador_07 * Played game in 2007 but attrited for 2010, 290 obs: foreach x in totinc_07 lntotinc_07 famsz_07 jug_sexo_07 jug_edad_07 jug_educ_07 risk1_07 time_07 sent_anon_07 c100b_07 { *(13) played game in 2007 and in 2010 sum `x' if stayg7g10==1 *(14) played game in 2007 but not in 2010 sum `x' if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508) & stayg7g10==0 * Regressions comparing (13) and (14) reg `x' stayg7g10 if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508), robust quietly reg `x' stayg7g10 if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508), cluster(comp) bootwildct stayg7g10 if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508), hypothesis(0) bootreps(10000) numvars(1) reg `x' stayg7g10 _I* if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508), robust quietly reg `x' stayg7g10 _I* if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508), cluster(comp) bootwildct stayg7g10 _I* if sent_anon_07!=. & (game0709!=0 | hhid91==9083 | hhid91==9508), hypothesis(0) bootreps(10000) numvars(1) } log close