I have a pooled panel data. The model is Yi,t+j=aj*Xi,t +bi,t (fixed effect) +... To make it simple, suppose j=0 and 1. The model simplifies to Yi,t+j=a0*Xi,t +a1*Xi,t+bi,t +... What I want is the panel data regression by group j; i.e., a1=0 when j=0 & a0=0 when j=1. I'm wondering if I could use command: bysort j: xtreg Y X i.i#i.t, fe. If this command does work, does it have the same bi,t across groups j=0 and 1? (this is what I want) If not, is there any alternative? Thanks a lot!