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: cox model with shared frailty
From
Maarten buis <[email protected]>
To
[email protected]
Subject
Re: st: cox model with shared frailty
Date
Thu, 22 Apr 2010 10:03:45 +0000 (GMT)
--- On Thu, 22/4/10, Tracy Clegg wrote:
> Hi, I am having a few problems with running a cox
> propotional hazard model with a shared frailty.
> My problem is that it is taking around 12 hours to
> run a model with just one predictor, does anyone know
> how I can speed up the model? I am using STATA/SE version 11.
>
> In my data I have over 10,000 animals which are clustered
> into 1,662 herds with between 6 and 12 animals in each herd.
> To add a further complication I have 2 predictors which are
> time varying.
I can see why that is taking long. I would do two things:
1) build your model on a dataset that contains only a sample
of your total data. I would sample herds not animals. So
say the variable identifying the herd is called herd, then
I would start my .do-file with
use complete_data.dta, clear
set seed 12345
bys herd: gen u = runiform()
bys herd (u): replace u = sum(u)
keep if u < .25 // keep 25% of the herds
drop u
2) Look around your departement to see if some computers
are going to remain unused for some days (because of
vacation/conference/field work/etc.), and ask those persons
if you can use their computer to run your complete model on.
Hope this helps,
Maarten
--------------------------
Maarten L. Buis
Institut fuer Soziologie
Universitaet Tuebingen
Wilhelmstrasse 36
72074 Tuebingen
Germany
http://www.maartenbuis.nl
--------------------------
*
* 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/