|From||"Yvonne Capstick" <firstname.lastname@example.org>|
|Subject||Re: st: Dummy variables for pooled regressions|
|Date||Thu, 12 Jan 2006 09:37:02 -0500|
From: austin nichols <email@example.com>_________________________________________________________________
Subject: Re: st: Dummy variables for pooled regressions
Date: Wed, 11 Jan 2006 11:26:59 -0500
. egen g=group(state ind)
. areg y x, absorb(g)
On 1/11/06, Yvonne Capstick <firstname.lastname@example.org> wrote:
> I'm trying to run a regression of company profit on many potential
> determinants (e.g. past advertising, past sales growth). I have a large
> dataset of many companies and am doing a pooled regression, pooling all of
> the observations together. I would like to include two dummy variables as
> controls: one for the state, and a second for the industry (i.e. state and
> industry year fixed effects).
> Is there a simple way to do this without literally creating a separate dummy
> variable for each state and each industry? I know that with a panel dataset
> (i.e. multiple cross sections over time), I can do xtreg y x, i(industry) fe
> if I am only interested in constructing an industry fixed effect. This
> syntax instructs Stata to create the dummy variables so I do not have to.
> However, if I need more than one fixed effect (industry and state), xtreg
> cannot seem to accommodate this. It only lets me put one variable in the i(
> ) option. Could anyone suggest an alternative way?
> Don't just search. Find. Check out the new MSN Search!
> * For searches and help try:
> * http://www.stata.com/support/faqs/res/findit.html
> * http://www.stata.com/support/statalist/faq
> * http://www.ats.ucla.edu/stat/stata/
* For searches and help try: