[R] median survival time from survfit
Marc Schwartz
marc_schwartz at me.com
Fri Mar 18 13:34:38 CET 2011
On Mar 18, 2011, at 6:06 AM, Dunia Scheid wrote:
> Hello,
>
> I am trying to compute the mdeian of the survival time from the function
> survfit:
>
>> fit <- survfit(Surv(time, status) ~ 1)
>> fit
> Call: survfit(formula = Surv(time, status) ~ 1)
>
> records n.max n.start events median 0.95LCL 0.95UCL
> 111 111 111 20 NA NA NA
>
> The results is NA? the fit$surv gives values between 1 and 0.749! Am I doing
> this correct? Is there a correct way to do this?
>
> Many thanks for your help,
> Dunia
Median survival is the time at which the survivorship function equals 0.5. Since your minimum value appears to be 0.749, you never get there, thus the output shows NA.
If you did not have any censored observations, median survival would also be the point at which 50% of your sample has not yet observed the event of interest.
See ?print.survfit for additional information specific to this function.
HTH,
Marc Schwartz
More information about the R-help
mailing list