plot_years: Plot the years measure

View source: R/years.R

plot_yearsR Documentation

Plot the years measure

Description

Plot the years measure obtained from the years function.

Usage

plot_years(
  years,
  xlab = "Time interval",
  ylab = "Years",
  xbreak,
  ybreak,
  xlimits,
  ylimits,
  conf.int = TRUE,
  ymirror = FALSE,
  yminus = FALSE
)

Arguments

years

the object obtained using function years.

xlab

a title for the x axis.

ylab

a title for the y axis.

xbreak

the breaks on the x axis (this is supplied to scale_x_continuous).

ybreak

the breaks on the y axis (this is supplied to scale_y_continuous).

xlimits

define the limits on the x axis (this is supplied to scale_x_continuous).

ylimits

define the limits on the y axis (this is supplied to scale_y_continuous).

conf.int

if TRUE, the confidence interval is plotted.

ymirror

mirror the y values (w.r.t. the x axis).

yminus

use function y -> -y when plotting.

Details

A ggplot2 implementation for plotting the years measure. The type of curve is dependent upon the measure calculated using the years function (argument measure).

Value

A ggplot object

See Also

years, plot_f


relsurv documentation built on March 18, 2022, 5:15 p.m.

Related to plot_years in relsurv...