mixsurv {flexsurvcure} | R Documentation |
Mixture cure models
Description
Probability density, distribution, quantile, random generation, hazard cumulative hazard, mean, and restricted mean functions for generic mixture cure models. These distribution functions take as arguments the corresponding functions of the base distribution used.
Usage
pmixsurv(pfun, q, theta, ...)
hmixsurv(dfun, pfun, x, theta, ...)
Hmixsurv(pfun, x, theta, ...)
dmixsurv(dfun, pfun, x, theta, ...)
qmixsurv(qfun, p, theta, ...)
rmixsurv(qfun, n, theta, ...)
rmst_mixsurv(pfun, t, theta, ...)
mean_mixsurv(pfun, theta, ...)
Arguments
pfun |
The base distribution's cumulative distribution function. |
theta |
The estimated cure fraction. |
... |
additional parameters to be passed to the pdf or cdf of the base distribution. |
dfun |
The base distribution's probability density function. |
x , q , t |
Vector of times. |
qfun |
The base distribution's quantile function. |
p |
Vector of probabilities. |
n |
Number of random numbers to simulate. |
Value
dmixsurv
gives the density, pmixsurv
gives the
distribution function, hmixsurv
gives the hazard and
Hmixsurv
gives the cumulative hazard.
qmixsurv
gives the quantile function, which is computed by crude
numerical inversion.
rmixsurv
generates random survival times by using qmixsurv
on a sample of uniform random numbers. Due to the numerical root-finding
involved in qmixsurv
, it is slow compared to typical random number
generation functions.
mean_mixsurv
and rmst_mixsurv
give the mean and restricted
mean survival times, respectively.
Author(s)
Jordan Amdahl <jrdnmdhl@gmail.com>