Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, statalist.org is already up and running.


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

Re: st: nlcom and delta method


From   Maarten buis <maartenbuis@yahoo.co.uk>
To   statalist@hsphsun2.harvard.edu
Subject   Re: st: nlcom and delta method
Date   Tue, 3 Aug 2010 16:59:31 +0000 (GMT)

--- On Tue, 3/8/10, Beatrice Crozza wrote:
> I did a maximum likelihood, using delta method, to get the
> values.
> 
> So, for example, one result of my maximum likelihood using
> delta method is this one:
> 
> 
> . nlcom (a: 1/(1+exp(-[ar]_b[_cons])))
> 
> Now I wan to test a no linear combinations, using the
> coefficient of a , however the usual command for the
> coefficient: _b[a] doesn't work.

if you want to access _b[a] then the command that created
a must be an estimation command, and by default -nlcom-
is not an estimation command. You can turn -nlcom- into
an estimation command by specifying the -post- option.
However now the results of your previous maximum 
likelihood command are overwritten. So this won't work if 
you want to use parameters from your maximum likelihood
command. In that case it is probably best to do the entire
opperation in one -nlcom- command. In that case it is 
often convenient to store a string containing the command
used to create a (n.b. not the value but the command) in
a local. Say that your second non-linear combination is
a / [ar]_b[x], then I would do that as follows:

local a "( 1/(1+exp(-[ar]_b[_cons])) )" 
nlcom (b: `a'/[ar]_b[x])

Hope this helps,
Maarten

--------------------------
Maarten L. Buis
Institut fuer Soziologie
Universitaet Tuebingen
Wilhelmstrasse 36
72074 Tuebingen
Germany

http://www.maartenbuis.nl
--------------------------



      

*
*   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–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index