I am running three models comparing a Random Effects model, a Fixed Effects Model and a Fixed Effects Instrumental Variable model. For the FE regressions I am using xtivreg, which drops singleton groups. I would like to use the same data for the RE models. My number of observations should be the same for all three regressions. The RE regressions include singleton groups so N is higher. I have tried using e(sample) which did not work. I would like to drop singleton groups. I have tried:
bys panelvar: drop if _N ==1 This also did not work as, it dropped more observations than singleton groups detected and causes the difference between my FE regressions and RE rgression observations to be even larger. Not sure how to go about this, any suggestions? Thanks!