Statalist


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

RE: st: xtlogit is slow


From   "Joseph Coveney" <[email protected]>
To   "Statalist" <[email protected]>
Subject   RE: st: xtlogit is slow
Date   Tue, 8 Jul 2008 21:56:49 +0900

Mitchell F. Berman wrote:

Good thought on the xtlogit issue, but no, the if clause is not the
problem.  Takes closer to an hour, I think, for the entire data set, but
I've only done this once.  I can tell that it is running slowly, because
each iteration takes many minutes.
I sent this issue in to Stata Tech Support.  I'm hoping they investigate it.

--------------------------------------------------------------------------------

I'm curious to see what they discover, because the do file below, which has
15 variables, 300,000 observations, and the command line that you showed
earlier in the thread takes only 2.5 minutes (149.9250 seconds) on my
boat-anchor-disguised-as-a-PC.  There must be something very peculiar about
your particular dataset or machine set up.

Joseph Coveney

clear *
set more off
set memory 100M
set seed `=date("2008-07-08", "YMD")'
set obs 300000
*
generate byte depvar = uniform() > 0.5
generate byte catvar1 = floor(4 * uniform())
forvalue i = 1/12 {
generate float other_var`i' = uniform()
}
generate byte rand = floor(9 * uniform())
generate int panelvar = floor(3000 * uniform())
timer clear 1
timer on 1
xi: xtlogit depvar i.catvar1 other_var* if rand <7, i(panelvar) pa
timer off 1
timer list
exit


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