Hello. Running R 4.2.3 on Windows 10. Using survimer package version survminer_0.4.9 published 2021-03-09.
I'm encountering an error with ggsurvplot() in the survminer package. Email to the author/maintainer about 2 weeks ago has not yet resulted in a reply. I seem unable to produce a n.censor.table for an unconditional (no predictor) survival curve. See code below. Any advice? Thanks. --Chris Ryan, MD, MS, MSPH library(survival) library(survminer) data(lung) fit <- survfit(Surv(time, status) ~ 1, data = lung) ggsurvplot( fit, data = lung, xlab = "Time in days", ncensor.plot = TRUE ) ## produces error "Error: ! Problem while converting geom to grob. ℹ Error occurred in the 1st layer. Caused by error: ! Unknown colour name: strata" about "uknown colour name strata" ## but there are no strata ## omit ncensor.plot, and no error ggsurvplot( fit, data = lung, xlab = "Time in days", # ncensor.plot = TRUE ) ## restore ncensor.plot = TRUE, but use a predictor in the model, ## and no error. fit.2 <- survfit(Surv(time, status) ~ sex, data = lung) ggsurvplot( fit.2, data = lung, xlab = "Time in days", ncensor.plot = TRUE ) ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see 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.