A function to produce predictions from MCMC output. These could include quantiles of the individual density, survival or hazard functions or quantiles of the density function (if available analytically).
# S3 method for mcmcspatsurv
predict(
object,
type = "density",
t = NULL,
n = 110,
indx = NULL,
probs = c(0.025, 0.5, 0.975),
plot = TRUE,
pause = TRUE,
bw = FALSE,
...
)
the required predictions
an object of class mcmcspatsurv
can be "density", "hazard", "survival" or "densityquantile". Default is "density". Note that "densityquantile" is not always analytically tractable for some choices of baseline hazard function.
optional vector of times at which to compute the quantiles, Defult is NULL, in which case a uniformly spaced vector of length n from 0 to the maximum time is used
the number of points at which to compute the quantiles if t is NULL
the index number of a particular individual or vector of indices of individuals for which the quantiles should be produced
vector of probabilities
whether to plot the result
logical whether to pause between plots, the default is TRUE
Logical. Plot in black/white/greyscale? Default is to produce a colour plot. Useful for producing plots for journals that do not accept colour plots.
other arguments, not used here
print.mcmcspatsurv, quantile.mcmcspatsurv, summary.mcmcspatsurv, vcov.mcmcspatsurv, frailtylag1, spatialpars, hazardpars, fixedpars, randompars, baselinehazard, priorposterior, posteriorcov, MCE, hazardexceedance