[R] Warning trying to plot -log(log(survival))
smckinney at bccrc.ca
Tue May 12 04:04:58 CEST 2009
I can't reproduce your case with built-in data sets.
Your data set is small. Can you show the data for the
variables involved in your example?
(Time30, Died, Rx, Age)
Steven McKinney, Ph.D.
Molecular Oncology and Breast Cancer Program
British Columbia Cancer Research Centre
email: smckinney at bccrc.ca
tel: 604-675-8000 x7561
675 West 10th Ave, Floor 4
> -----Original Message-----
> From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
> project.org] On Behalf Of John Sorkin
> Sent: Monday, May 11, 2009 12:19 PM
> To: r-help at stat.math.ethz.ch
> Subject: [R] Warning trying to plot -log(log(survival))
> windows xp
> R 2.8.1
> I am trying to plot the -log(log(survival)) to visually test the
> proportional hazards assumption of a Cox regression. The plot, which
> should give two lines (one for each treatment) gives only one line and
> a warning message. I would appreciate help getting two lines, and an
> explanation of the warning message. My problem may the that I have
> few events in one of my strata, but I don't know.
> WARNING: Warning in xy.coords (x, y, xlabel, ylabel, log) :
> 2 x values <=0 omitted from logarithmic plot
> > print(survfit(fit0),fun="cloglog")
> Call: survfit.coxph(object = fit0)
> n events median 0.95LCL 0.95UCL
> Rx=0 31 5 Inf Inf Inf
> Rx=1 32 15 Inf 1.17 Inf
> John David Sorkin M.D., Ph.D.
> Chief, Biostatistics and Informatics
> University of Maryland School of Medicine Division of Gerontology
> Baltimore VA Medical Center 10 North Greene Street GRECC (BT/18/GR)
> Baltimore, MD 21201-1524
> (Phone) 410-605-7119
> (Fax) 410-605-7913 (Please call phone number above prior to faxing)
> Confidentiality Statement:
> This email message, including any attachments, is for
> R-help at r-project.org mailing list
> PLEASE do read the posting guide http://www.R-project.org/posting-
> and provide commented, minimal, self-contained, reproducible code.
More information about the R-help