grid.draw_ggsurvfit | R Documentation |
grid::grid.draw()
methods for objects of classes 'ggsurvfit' and 'ggcuminc'.
These are implemented to allow users to directly call ggplot2::ggsave()
on 'ggsurvfit' figures.
## S3 method for class 'ggsurvfit'
grid.draw(x, recording = TRUE)
## S3 method for class 'ggcuminc'
grid.draw(x, recording = TRUE)
x |
an object of class 'ggsurvfit' or 'ggcuminc' |
recording |
A logical value to indicate whether the drawing operation should be recorded on the Grid display list. |
None
survfit2(Surv(time, status) ~ surg, data = df_colon) %>%
ggsurvfit() %>%
grid.draw()
library(tidycmprsk)
cuminc(Surv(ttdeath, death_cr) ~ trt, trial) %>%
ggcuminc() %>%
grid.draw()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.