[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: xtreg with constraints?

From   Maarten buis <>
Subject   Re: st: xtreg with constraints?
Date   Mon, 11 Feb 2008 16:30:30 +0000 (GMT)

--- Serguei Kaniovski <> wrote:
> how can I implement coefficient constrains in a STATA panel
> regression? The "xtreg" command does not seem to take the "cons"-
> option.

True, one work around that will work in some instances is to create
variables that impose the constraint that you want. A common constraint
is that the effects of two variables are equal. In that case you can
create a new variable equal to the sum of the two variables and add
that to your model (and leave the two variables out). The reason for
that is as follows. Your unconstrained model is:

y = b0 + b1 x1 + b2 x2 + ...

You want to constrain b1 to be equal to b2, so you can just as well

  = b0 + b1 x1 + b1 x2 + ...

which you can simplify as: 

  = b0 + b1 (x1 + x2) + ...

Hope this helps,

Maarten L. Buis
Department of Social Research Methodology
Vrije Universiteit Amsterdam
Boelelaan 1081
1081 HV Amsterdam
The Netherlands

visiting address:
Buitenveldertselaan 3 (Metropolitan), room Z434

+31 20 5986715

Sent from Yahoo! Mail - a smarter inbox

*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index