Notice: On March 31, it was **announced** that Statalist is moving from an email list to a **forum**. The old list will shut down at the end of May, and its replacement, **statalist.org** is already up and running.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

From |
Natalie Trapp <natalie.trapp@zmaw.de> |

To |
statalist@hsphsun2.harvard.edu |

Subject |
Re: st: re: binary variables |

Date |
Thu, 03 Jun 2010 17:16:54 +0200 |

Thank you so much for all the comments. They were very helpful.

So, thank you very much once again. You gave me many more ideas! Natalie On 6/3/2010 11:58 AM, Christopher Baum wrote:

<> Natalie said I also couldn't sort out how to make the "xtreg" command work. It gives me the error "not sorted r(5);", even when I sorted the data and then typed the "xtreg" command (maybe because there are too many variables or maybe because I have cross sectional data?!). I imagine you tried to include those explicit region variables (Saarland Brandenburg MeckPomm Sachsen, etc.) in xtreg, fe. You can't include region dummies and fit a fixed effects model. All you need to do is xtreg depvar indepvars, fe i(REGION) and Stata will fit the model using the within transformation (equivalent to including dummies for each REGION). To see that this works: webuse grunfeld tsset, clear xtreg invest mvalue kstock, i(company) fe Note that the sort order does not matter. You can randomly sort the observations in the dataset and the above FE model will still work. Kit Kit Baum | Boston College Economics& DIW Berlin | http://ideas.repec.org/e/pba1.html An Introduction to Stata Programming | http://www.stata-press.com/books/isp.html An Introduction to Modern Econometrics Using Stata | http://www.stata-press.com/books/imeus.html * * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/

* * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/

**Follow-Ups**:**Re: st: re: binary variables***From:*Clive Nicholas <clivelists@googlemail.com>

**AW: st: re: binary variables***From:*"Martin Weiss" <martin.weiss1@gmx.de>

**References**:**st: re: binary variables***From:*Christopher Baum <kit.baum@bc.edu>

- Prev by Date:
**st: save two-way tables as a dataset** - Next by Date:
**st: AW: save two-way tables as a dataset** - Previous by thread:
**st: re: binary variables** - Next by thread:
**AW: st: re: binary variables** - Index(es):