I'm interested in estimating a linear model with random parameters (RP) and some endogenous regressors in stata. The main issue is to obtain estimates of parameters variances and not the parameters by themself (a two stage method provides unbiased parameter estimates). Is there any specific setup within SEM or GLLAMM modules to do an straight estimation of this model ?
A two stage method will at best provide consistent estimates. You can forget about anything unbiased in the GLLAMM or SEM world, trust me.
GLLAMM would be able to handle enodgeneity by explicitly modeling it. Is that something that you intend to pursue? Generally economists are unhappy about modeling endogeneity, and would rather prefer an estimation method that is robust to endogeneity, like instrumental variables.
Without knowing more about your model, it is impossible to tell what the
xtmixed (which is probably more appropriate than
sem here), let alone
gllamm, set up could be.