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: Mlogit Nonresulting Large Dataset
From
Richard Williams <[email protected]>
To
[email protected], [email protected]
Subject
Re: st: Mlogit Nonresulting Large Dataset
Date
Mon, 09 Sep 2013 02:02:41 -0500
At 12:12 AM 9/9/2013, Mike Butterfield wrote:
Hi Statalisters,
I am using a subpopulation of the National Inpatient Sample, about 3million
cases, and looking at different predictors for discharge types (0 = routine
1= died in hospital 2= to SNF/nursing home), controlling with Elixhauser
comorbidities.
Stata can give me results with many of my predictor variables within about
10 minutes. However, when I use an ordinal predictor variable (eg hospital
type small/medium/large), nothing happens, I've left it running for a day
or two without any sign that data will be resulted. Any ideas on what
could be going wrong?
I'm using a Mac with 8g of ram and stata 12.
Here's the basic command function:
svy, subpop(AGE if AGE>=18&AGE<=90): mlogit discharge HOSP_SIZE elix1 elix2
elix3 elix4 ...[through elix 30]
Hard to tell without having the data, but a few thoughts:
* Does the exact same command work if you drop HOSP_SIZE? Make sure
that HOSP_SIZE is really the problem. Also, I suppose you could see
what happens when you only include HOSP_SIZE as a predictor variable.
* Have you done descriptives for HOSP_SIZE? Make sure it doesn't have
some weird values, e.g. isn't coded 1, 2, 3, 99.
* You might try a crosstab of discharge by HOSP_SIZE to see if
anything seems unusual, e.g. HOSP_SIZE is a constant or nearly so
when discharge = 1. Also, HOSP_SIZ isn't super highly correlated with
the elix variables, is it?
* You could add the -noisily- option to svy and see if anything seems
to be happening. Maybe you'll get a bunch of "not concave" messages.
* sometimes adding the -difficult- option to the mlogit part of the
command works miracles if the model is not converging.
* You say Stata 12. Do you really mean that, or do you mean Stata
12.1? If you really are running Stata 12, do
update all
to get the latest version.
* As a sidelight, I think your subpop statement could be
svy, subpop(if AGE>=18&AGE<=90)
You might do something like
gen mysampl= AGE>=18&AGE<=90
and then run stats with mysampl just to make sure sample selection is
going the way you want it to.
-------------------------------------------
Richard Williams, Notre Dame Dept of Sociology
OFFICE: (574)631-6668, (574)631-6463
HOME: (574)289-5227
EMAIL: [email protected]
WWW: http://www.nd.edu/~rwilliam
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/