A very belated thank you for a solution that you gave months ago (and that
I could get back to only now). It worked perfectly, thanks!
Puja
Date: Fri, 25 Jun 2004 14:03:22 -0500
From: "Scott Merryman" <[email protected]>
Subject: st: RE: Estimating sqreg without a constant
Puja,
Could you not add the value of the constant to the estimated dummy variables
(where the dropped dummy variable takes on the value of the constant)?
For example, the following creates a new variable of the fixed-effect for
each company:
use http://www.stata-press.com/data/r8/grunfeld.dta
xi i.com
qui qreg invest mvalue kstock _I*,
gen fe = .
forv i = 1/10 {
qui replace fe = _b[_Icompany_`i'] + _b[_cons] if company == `i'
*local j = `j' +1
}
replace fe =_b[_cons] if company == 1