NEWS


survminer 0.5.0.999

New features

Major changes

Minor changes

Bug fixes

survminer 0.5.0 (2024-10-30)

Minor changes

Bug fixes

survminer 0.4.9 (2021-03-09)

Minor changes

Bug fixes

survminer 0.4.8 (2020-07-25)

Minor changes

survminer 0.4.7 (2020-05-28)

Minor changes

Fixes to adapt to dplyr 1.0.0 (@romainfrancois, #460):

Bug fxes

survminer 0.4.6 (2019-09-03)

New features

Minor changes

survminer 0.4.5 (2019-08-03)

Minor changes

Bug fixes

survminer 0.4.4 (2019-05-21)

Minor changes

Bug fixes

survminer 0.4.3 (2018-08-04)

New features

Minor changes

Bug fixes

survminer 0.4.2 (2018-01-31)

Minor changes

Bug fixes

survminer 0.4.1 (2017-11-17)

New features

Major changes

Minor changes

Bug fixes

survminer 0.4.0 (2017-06-07)

New features

New options in ggsurvplot()

New functions

Major changes

Minor changes

For example, in the following script, survival curves are colored by the grouping variable sex in all facets:

library(survminer)
library(survival)
fit <- survfit( Surv(time, status) ~ sex + rx + adhere,
                 data = colon )
ggsurv <- ggsurvplot(fit, data = colon,
               color = "sex",
               legend.title = "Sex",
               palette = "jco")
ggsurv$plot + facet_grid(rx ~ adhere)

Bug fixes

survminer 0.3.1 (2017-03-21)

Minor changes

Bug fixes

survminer 0.3.0 (2017-03-16)

New features

New options in ggsurvplot()

Themes

# Fit survival curves
require("survival")
fit<- survfit(Surv(time, status) ~ sex, data = lung)

# Survival curves
require("survminer")
ggsurvplot(fit, data = lung, risk.table = TRUE,
    tables.theme = theme_cleantable()
    )

New functions

# Fit survival curves
require("survival")
fit<- survfit(Surv(time, status) ~ sex, data = lung)

# Basic survival curves
require("survminer")
p <- ggsurvplot(fit, data = lung, risk.table = TRUE)
p

# Customizing the plots
p %+% theme_survminer(
     font.main = c(16, "bold", "darkblue"),
     font.submain = c(15, "bold.italic", "purple"),
     font.caption = c(14, "plain", "orange"),
     font.x = c(14, "bold.italic", "red"),
     font.y = c(14, "bold.italic", "darkred"),
     font.tickslab = c(12, "plain", "darkgreen")
)

Helper functions

New heper functions ggrisktable(), ggcumevents(), ggcumcensor(). Normally, users don't need to use these function directly. Internally used by the function ggsurvplot().

Major changes

Minor changes

require(survival)
require(ReporteRs)
require(survminer)

fit <- survfit(Surv(time, status) ~ rx + adhere, data =colon)
survplot <- ggsurvplot(fit, pval = TRUE,
                       break.time.by = 400,
                       risk.table = TRUE,
                       risk.table.col = "strata",
                       risk.table.height = 0.5, # Useful when you have multiple groups
                       palette = "Dark2")


require(ReporteRs)
doc = pptx(title = "Survival plots")
doc = addSlide(doc, slide.layout = "Title and Content")
doc = addTitle(doc, "First try")
doc = addPlot(doc, function() print(survplot, newpage = FALSE), vector.graphic = TRUE)
writeDoc(doc, "test.pptx")

Bug fixes

Vignettes and examples

survminer 0.2.4 (2016-12-11)

Bug fixes

survminer 0.2.3 (2016-12-07)

New features

# Fit complexe survival curves
require("survival")
fit3 <- survfit( Surv(time, status) ~ sex + rx + adhere,
                data = colon )
                
# Visualize by faceting
# Plots are survival curves by sex faceted by rx and adhere factors.
require("survminer")  
ggsurv$plot +theme_bw() + facet_grid(rx ~ adhere)

Minor changes

Bug fixes

survminer 0.2.2 (2016-07-28)

New features

Bug fixes

survminer 0.2.1 (2016-04-23)

New features

Minor changes

Bug fixes

survminer 0.2.0 (2016-02-18)

New features

# Fit survival curves
require("survival")
fit<- survfit(Surv(time, status) ~ sex, data = lung)

# visualize
require(survminer)
ggsurvplot(fit, pval = TRUE, conf.int = TRUE,
          risk.table = TRUE)

# Customize the output and then print
res <- ggsurvplot(fit, pval = TRUE, conf.int = TRUE,
           risk.table = TRUE)
res$table <- res$table + theme(axis.line = element_blank())
res$plot <- res$plot + labs(title = "Survival Curves")
print(res)

Minor changes

Bug fixes

survminer 0.1.1 (2016-01-18)

New features