Code:
nbreg overlap_days independent_vars if drug1_days>0, exposure(drug1_days) vce(cluster patient_id) difficult
However, a Poisson model (same as above, but substitute poisson for nbreg) of the same data does converge (quickly).
Interestingly, if I run the nbreg model starting from the poisson estimates, the nbreg model converges with no problems.
Code:
poisson overlap_days independent_vars if drug1_days>0, exposure(drug1_days) vce(cluster patient_id) difficult matrix b0=e(b) matrix b1=J(1,126,1) matrix b1[1,1]=b0 nbreg overlap_days independent_vars if drug1_days>0, exposure(drug1_days) vce(cluster patient_id) difficult from(b1, copy)
Note that there are a large number of variables in the model, hence the size of the b1 matrix, but I have 13 million observations.
0 Response to nbreg only converges when starting from poisson estimates
Post a Comment