powered by
Generates a Cumulative Log Log survival curve plot using ggsurvfit::ggsurvfit() with customizable options.
ggsurvfit::ggsurvfit()
plot_cloglog( fit, median_line = FALSE, legend_position = "top", plot_theme = theme_easysurv() )
A ggplot object representing the cumulative log log plot.
A survival::survfit object representing the survival data.
Logical value indicating whether to include a line representing the median survival time. Default is FALSE.
FALSE
Position of the legend in the plot. Default is "top".
ggplot2 theme for the plot. Default is theme_easysurv().
theme_easysurv()
library(ggsurvfit) fit <- survfit2(Surv(time, status) ~ surg, data = df_colon) plot_cloglog(fit)
Run the code above in your browser using DataLab