Statalist The Stata Listserver


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: Slow performance with mlogit


From   Richard Williams <[email protected]>
To   [email protected]
Subject   Re: st: Slow performance with mlogit
Date   Sun, 18 Feb 2007 22:20:40 -0500

At 03:25 PM 2/18/2007, Mike Lacy wrote:
I'm running -mlogit- on a large data file (N = about 165,000 cases), with 3 outcomes. -mlogit- has been quite slow, taking several minutes for some models. So, for a comparison, I ran a model with 6 covariate, which required about 10 seconds of wall-clock in Stata (v9.2, under Win XP) but only about 1/4 second in SPSS. The SPSS coefficient estimates were identical to at least 4 or 5 significant digits to Stata's results, even though SPSS took a few more iterations. I have had other mlogit models with large N perform quite poorly in Stata as compared to SPSS. This seems a strange and unreasonable difference to me, and while 10 sec. vs. 1/4 sec for this particular model is not a big deal, several minutes for other models estimates in Stata is. Is there anything I might be able to "tune" in Stata here? The issue appears to be the time per iteration, not factors affecting the number of iterations required.
My first impulse was to add the -difficult- option, but alas it isn't supported by -mlogit-. So, just for the heck of it, you might see if -slogit- with the -dim- option fairs any better. Since you have 3 outcomes, you would have -dim(2)-. And, if that is slow, you could try adding -difficult-. I'd also use the baseoutcome option so that both mlogit and slogit were using the same base category.

I'd be pretty surprised if slogit was faster, but it won't hurt to try it.


-------------------------------------------
Richard Williams, Notre Dame Dept of Sociology
OFFICE: (574)631-6668, (574)631-6463
FAX: (574)288-4373
HOME: (574)289-5227
EMAIL: [email protected]
WWW (personal): http://www.nd.edu/~rwilliam
WWW (department): http://www.nd.edu/~soc
*
* 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/




© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index