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: estimation of SE of correlation after mixlogit


From   Nick Darson <[email protected]>
To   [email protected]
Subject   Re: st: estimation of SE of correlation after mixlogit
Date   Fri, 12 Aug 2011 21:50:01 +1000

Dear Arne,

Many thanks for your reply. I see now why my attempts using nlcom
(with "v21" instead of the l21/l11 etc combos) did not work.

And BTW: thank you very much for writing and sharing this great program!

Cheers,
Nick



On Fri, Aug 12, 2011 at 9:26 PM, Arne Risa Hole <[email protected]> wrote:
> Nick
>
> Note that -mixlogit-  is a user-written command which is available
> from the SSC and described in
> <http://www.stata-journal.com/article.html?article=st0133>.
>
> Running the following command after -mixlogit- (on one line) will give
> you the SE of the correlation:
>
> nlcom (rho: [l21]_b[_cons]*[l11]_b[_cons] /
> sqrt([l11]_b[_cons]*[l11]_b[_cons]*([l21]_b[_cons]*[l21]_b[_cons] +
> [l22]_b[_cons]*[l22]_b[_cons])))
>
> Arne
>
> On 12 August 2011 10:59, Nick Darson <[email protected]> wrote:
>> Hi listers,
>>
>> After running mixlogit, I am wondering how I exactly calculate the
>> standard error of the correlation.
>>
>> To my understanding, I have to do this manually after obtaining the
>> covariance-variance components using the command "mixlcov" (please
>> tell me if there is an easier automatic way that I have overlooked,
>> such as using nlcom - I have tried this but always get error
>> messages).
>>
>> For example, I have a multinomial model with three possible
>> alternatives: low, mid, high (low as the base case; mid and high are
>> random and allowed to be correlated).
>>
>> Hence, after estimation with mixlogit and using "mixlcov", I obtain
>> the values for v21, v11, and v22.
>>
>> This way I can easily calculate the correlation of the two variables:
>> rho= _b[v21] / sqrt (_b[v11] * _b[v22])
>>
>> However, how do I calculate the SE of this correlation?
>> I found the following formula:  SE(rho) =  sqrt ( 1-rho^2 / n -2 )
>>
>> However, which value do I use for "n"? In my case, I have repeated
>> measures (each of the 200 individuals makes 5 choices). Hence, should
>> I use n=200 (the number of subjects), n= 1000 (total number of
>> observations), or do I need to look how many cases actually have
>> chosen mid and high (e.g. let's say from the 1000 total choices, 200
>> are mid and 300 are high, hence n=500)?
>>
>> Thankful for any help on this apparently simple issue.
>>
>> Cheers,
>> Nick
>> *
>> *   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/
>>
>
> *
> *   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/
>

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