I am using a regression discontinuity design, with -
- Outcome variable: selfhealth (Self reported health index)
- Running variable: z_age (Age in years - 66.5, retirement age)
- Treatment variable: retire (1 if the individual is not in the labour force)
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input long hhidpn byte(wave selfhealth) float(z_age retire) 1010 1 4 -12.5 0 1010 2 4 -10.5 0 1010 3 . . . 1010 4 . . . 1010 5 . . . 1010 6 . . . 1010 7 . . . 1010 8 . . . 1010 9 . . . 1010 10 . . . 1010 11 . . . 1010 12 . . . 1010 13 . . . 2010 1 3 -9.5 1 2010 2 3 -7.5 0 2010 3 4 -4.5 1 2010 4 5 -3.5 1 2010 5 3 -1.5 1 2010 6 . . . 2010 7 . . . 2010 8 . . . 2010 9 . . . 2010 10 . . . 2010 11 . . . 2010 12 . . . 2010 13 . . . 3010 1 4 -10.5 0 3010 2 4 -8.5 0 3010 3 3 -6.5 1 3010 4 3 -4.5 1 3010 5 4 -2.5 1 3010 6 3 -.5 1 3010 7 3 1.5 1 3010 8 3 3.5 1 3010 9 3 5.5 1 3010 10 3 7.5 1 3010 11 3 9.5 1 3010 12 . . . 3010 13 . . . 3020 1 3 -12.5 1 3020 2 3 -11.5 1 3020 3 3 -9.5 1 3020 4 3 -7.5 1 3020 5 3 -5.5 1 3020 6 3 -3.5 1 3020 7 3 -1.5 1 3020 8 3 .5 1 3020 9 4 2.5 1 3020 10 4 5.5 1 3020 11 4 6.5 1 end label values selfhealth SHLT label def SHLT 3 "3.good", modify label def SHLT 4 "4.fair", modify label def SHLT 5 "5.poor", modify
Code:
rdrobust selfhealth z_age, fuzzy(retire) vce(cluster hhidpn)
Code:
. rdrobust selfhealth z_age, fuzzy(retire) vce(cluster hhidpn) <istmt>: 3301 subscript invalid r(3301);
0 Response to Using rdrobust with panel data, error 3301
Post a Comment