autoplotTAP: Arrange a survival plot with corresponding table and legend.

autoplotTableAndPlotR Documentation

Arrange a survival plot with corresponding table and legend.

Description

Arrange a survival plot with corresponding table and legend.

Usage

## S3 method for class 'tableAndPlot'
autoplot(object, ..., hideTabLeg = TRUE, tabHeight = 0.25)

Arguments

object

An object of class "tableAndPlot", as returned by ggplot.Ten.

...

Additional arguments (not implemented).

hideTabLeg

Hide table legend.
If hideTabLeg = TRUE (the default), the table legend will not appear.

tabHeight

Table height, as a fraction/ proportion of the whole.
tabHeight=0.25 (the default) makes the table 0.25 = 25\% of the whole plot height.

Details

Arguments to plotHeigth and tabHeight are best specified as fractions adding to 1,

Value

A graph, plotted with gridExtra::grid.arrange.

Note

This method is called by print.tableAndPlot and by print.stratTableAndPlot.

Author(s)

Chris Dardis. Based on existing work by R. Saccilotto, Abhijit Dasgupta, Gil Tomas and Mark Cowley.

Examples

## Not run: 
data("kidney", package="KMsurv")
autoplot(survfit(Surv(time, delta) ~ type, data=kidney), type="fill")
autoplot(ten(survfit(Surv(time, delta) ~ type, data=kidney)), type="fill")
data("bmt", package="KMsurv")
s2 <- survfit(Surv(time=t2, event=d3) ~ group, data=bmt)
autoplot(s2)

## End(Not run)

survMisc documentation built on April 7, 2022, 5:06 p.m.