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]

st: RE: correlation table for fixed effects negative binomial model


From   "Jacobs, David" <jacobs.184@sociology.osu.edu>
To   "'statalist@hsphsun2.harvard.edu'" <statalist@hsphsun2.harvard.edu>
Subject   st: RE: correlation table for fixed effects negative binomial model
Date   Tue, 8 May 2012 21:11:47 +0000

Create a variable equal to the State phrase -e(sample)- immediately after run.  

Stata command -generate smple=e(sample)- will create a dummy named smple equal to one for any case that was in the immediately preceding model.  Then use this dummy in an if statement to limit your correlation matrix to these cases.

Dave Jacobs

-----Original Message-----
From: owner-statalist@hsphsun2.harvard.edu [mailto:owner-statalist@hsphsun2.harvard.edu] On Behalf Of Mukund Chari
Sent: Tuesday, May 08, 2012 4:45 PM
To: statalist@hsphsun2.harvard.edu
Subject: st: correlation table for fixed effects negative binomial model

Dear Stata users,


 I am trying to get the correlations matrix after running a fixed effects negative binomial model (xtnbreg). I cannot use the mkcorr command because it uses all the observations in the dataset, while the xtnbreg command drops observations for the groups for which it finds no variance, thus resulting in a mismatch on the number of observations between that of the regression and the correlation routines. Since I have a very large number of fixed effects (30000), I cannot use an unconditional fixed effects model with dummies as it would be computationally challenging.

 To get to the "true" correlations table, I could use the estat vce, corr   command after running the regression, but this would only return the estimates, and not the significance levels. I tried searching through the forum for appropriate solutions, but could not find any discussion on this topic.

 Any help would be much appreciated.

*This is my first post to the forum, please excuse any inadvertent violation of forum norms*

Best,
Mukund Chari.




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