[prev in list] [next in list] [prev in thread] [next in thread]
List: r-help
Subject: Re: [R] Calculate survival function for AFT model
From: David Winsemius <dwinsemius () comcast ! net>
Date: 2011-12-31 2:42:33
Message-ID: 45F3C6BA-BF12-47BB-9297-5BB0CAE790C4 () comcast ! net
[Download RAW message or body]
On Dec 30, 2011, at 6:19 PM, Milan Bouchet-Valat wrote:
> Le vendredi 30 d=E9cembre 2011 =E0 12:46 -0800, thebennjammin a =E9crit :
>> I have fit an accelerated failure time model using coxph, and have =
>> what seems
>> to be a simple question that I can't figure out.
> Please specify the exact package, functions and actual code you use.
> coxph(), as the name says, runs a Cox *proportional hazards* model,
> which is different from an accelerated failure time model.
I had the same puzzlement. I do think it is possible to construct some =
AFT models with survival::coxph using time in the rhs of the formula, =
but I do not think it is the recommended way, and I would feel much =
more comfortable using survreg as well.
> You should
> use survreg (package survival) if you want to run the later family.
>
>> Given a vector of predictor values X, the survival time S[t|X] is the
>> probability the entity will survive longer than some time t. Now, =
>> how do I
>> calculate this for a specific value of t?
> Package rms offers convenience functions to compute and plot this. See
> psm() and predict.psm().
In package survival the survfit function is the way to go if you want =
to recover S(t|X)
--
David Winsemius, MD
West Hartford, CT
______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic