Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Re: constraints


From   "Hannah Kewsberry" <[email protected]>
To   [email protected]
Subject   st: Re: constraints
Date   Wed, 18 Sep 2002 13:51:03 +0000

Dear Sir,

I have tried to work on the similar template on mlogit as you have suggested but Stata has given me the response:'invalid syntax'. Could you kindly suggest where have I gone wrong?

Thanks.

Regards

Hannah



---

Presuming that you are using linear regression,

g totearn = earn1 + earn2 + earn3
reg par e1 e2 e3 race status totearn

does this by substituting the constraint into the model. Alternatively,

cons def 1 earn1=earn2
cons def 2 earn1=earn3
cnsreg par e1 e2 e3 race status earn*, c(1 2)

Since you are applying two constraints to the coefficient vector (i.e. if you ran the unconstrained regression and tested earn1=earn2=earn3, you would be doing an F with 2 and ? d.f.), you must define two constraints.

_________________________________________________________________
MSN Photos is the easiest way to share and print your photos: http://photos.msn.com/support/worldwide.aspx

*
* 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/




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