Re: [R] Kaplan Meier function

From: Frank E Harrell Jr <f.harrell_at_vanderbilt.edu>
Date: Thu, 14 Feb 2008 11:57:42 -0600

Matthias Gondan wrote:
> Frank E Harrell Jr schrieb:

>> Matthias Gondan wrote:
>>>> data(colon)
>>>> s = survfit(Surv(time, status) ~ rx, data=colon)
>>>> plot(s)
>>>> plot(s, col=1:3)
>>> By the way: Does anyone know a neat way to indicate the number of
>>> patients under risk in
>>> the curve?
>> That's one of many options in the survplot function in the Design 
>> package, which uses the survival package.

>
> Ah, thanks! Nice.
>
> data(colon)
> s = survfit(Surv(time, status) ~ rx, data=colon)
> survplot(s, n.risk=TRUE, conf='none', time.inc=500)
>
> Is there an option for drawing small vertical lines if a patient has
> been censored?

No, I haven't been a big enough fan of that to implement it. You can write a few lines of code that runs after survplot().

Frank

>
> Best wishes,
>
> Matthias
>
> ______________________________________________
> R-help_at_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.
>

-- 
Frank E Harrell Jr   Professor and Chair           School of Medicine
                      Department of Biostatistics   Vanderbilt University

______________________________________________
R-help_at_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.
Received on Thu 14 Feb 2008 - 18:04:57 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Thu 14 Feb 2008 - 18:30:13 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive