ggcoxdiagnostics
function that plots diagnostic graphs for Cox Proportional Hazards model ([@MarcinKosinski, #16](https://github.com/kassambara/survminer/issues/16)).Survival plots have never been so informative
([@MarcinKosinski, #39](https://github.com/kassambara/survminer/issues/39))ggsurvplot()
documentation. ([@ViniciusBRodrigues, #43](https://github.com/kassambara/survminer/issues/43))New ggcoxzph
function that displays a graph of the scaled Schoenfeld residuals, along with a smooth curve using 'ggplot2'. Wrapper around . ([@MarcinKosinski, #13](https://github.com/kassambara/survminer/issues/13))
New ggcoxfunctional
function that displays graphs of continuous explanatory variable against martingale residuals of null cox proportional hazards model, for each term in of the right side of input formula. This might help to properly choose the functional form of continuous variable in cox model, since fitted lines with lowess
function should be linear to satisfy cox proportional hazards model assumptions. ([@MarcinKosinski, #14](https://github.com/kassambara/survminer/issues/14))
New function theme_classic2
: ggplot2 classic theme with axis line. This function replaces ggplot2::theme_classic, which does no longer display axis lines (since ggplot2 v2.1.0)
risk.table.y.text.col
is now TRUE.ggsurvplot
. logical argument. Default is TRUE. If FALSE, risk table y axis tick labels will be hidden ([@MarcinKosinski, #28](https://github.com/kassambara/survminer/issues/28)).New argument risk.table.y.text.col: logical value. Default value is FALSE. If TRUE, risk table tick labels will be colored by strata ([@MarcinKosinski, #8](https://github.com/kassambara/survminer/issues/8)).
print.ggsurvplot()
function added: S3 method for class 'ggsurvplot'.
It's now possible to customize the output survival plot and the risk table returned by ggsurvplot, and to print again the final plot. ([@MarcinKosinski, #2](https://github.com/kassambara/survminer/issues/2)):
# 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)
ggtheme now affects risk.table ([@MarcinKosinski, #1](https://github.com/kassambara/survminer/issues/1))
xlim changed to cartesian coordinates mode ([@MarcinKosinski, #4](https://github.com/kassambara/survminer/issues/4)). The Cartesian coordinate system is the most common type of coordinate system. It will zoom the plot (like you’re looking at it with a magnifying glass), without clipping the data.
Risk table and survival curves have now the same color and the same order
Plot width is no longer too small when legend position = "left" ([@MarcinKosinski, #7](https://github.com/kassambara/survminer/issues/7)).