--- Gernot Wagner <[email protected]> wrote:
> How do I implement a nonlinear likelihood-ratio test in a SUR
> context?
Gernot:
You can do a Wald-type test based on the delta method with -testnl- or
-nlcom-. See the example below. If you really want to do the likelihood
ratio test then you'll have to program a -sureg-like program that
contains the constraint yourself and compare the log likelihoods. I
don't think that is worth the effort, given the availability of
-testnl- and -nlcom-.
HTH,
Maarten
*---------- begin example -----------------
sysuse auto, clear
sureg (price foreign weight length) (mpg displ = foreign weight)
testnl _b[price:foreign]/_b[mpg:weight]=_b[price:length]
return list
nlcom example:_b[price:foreign]/_b[mpg:weight]-_b[price:length], post
di %18.14f (_b[example]/_se[example])^2
/*compare with chi2 from -testnl-*/
*------------- end example ----------------
-----------------------------------------
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
http://home.fsw.vu.nl/m.buis/
-----------------------------------------
___________________________________________________________
All new Yahoo! Mail "The new Interface is stunning in its simplicity and ease of use." - PC Magazine
http://uk.docs.yahoo.com/nowyoucan.html
*
* 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/