Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


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

Re: st: wald test when I use GMM method in stata 11


From   Austin Nichols <[email protected]>
To   [email protected]
Subject   Re: st: wald test when I use GMM method in stata 11
Date   Thu, 20 Jan 2011 13:30:39 -0500

Song Nhac <[email protected]> :
Look at the coef vector first:

sysuse auto, clear
ren price y
ren mpg a
ren foreign b
g aXb=a*b
gmm (y:y-{c0}-{c1}*a-{c2}*b-{c3}*aXb), inst(a b aXb)
mat li e(b)
test [c2]_cons+[c3]_cons=0
qui reg y a b aXb
mat li e(b)
test b+aXb=0
qui reg y c.a##i.b
mat li e(b)
test 1.b+1.b#c.a=0


On Thu, Jan 20, 2011 at 7:39 AM, Song Nhac <[email protected]> wrote:
> Dear Statalist,
>
> I have a problem after doing GMM in Stata11- I would like to do a wald
> test for 2 coefficient but it reports an error. Please see following:

> test b + aXb = 0
> regressor b not found
> r(111);
>
> I tried it many times, but it alway says that regressor b not found. I
> don't know what happens in this since I am not expert in 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/


© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index