Learn R Programming

FunSurv (version 1.0.0)

plot.funsurv: Plot method for 'funsurv' objects

Description

Plot method for 'funsurv' objects

Usage

# S3 method for funsurv
plot(x, what = c("beta", "fpc", "basesurv"), ...)

Value

A ggplot object ...

Arguments

x

A funsurv object

what

A character string specifying what to be plotted. Use what = "beta" to plot the estimated \(\beta(t)\). Use what = "fpc" to plot the functional principal components associated with the the longitudinal measurements. Use what = "basesurv" to plot the baseline survival probabilities.

...

additional graphical parameters to be passed to methods.

Examples

Run this code
data(simDat)
fit <- AR1_FRAILTY(Recur(t_start %to% t_stop, id, status) ~ z1,
                   sdat = sdat, fdat = fdat, iter.max = 30)
plot(fit, what = "beta")
plot(fit, what = "fpc")
plot(fit, what = "basesurv")

Run the code above in your browser using DataLab