This function continues the sampling from the MCMC chains of an existing object of class 'JointAI'.

add_samples(object, n.iter, add = TRUE, thin = NULL,
monitor_params = NULL, progress.bar = "text", mess = TRUE)

## Arguments

object

object inheriting from class 'JointAI'

n.iter

the number of additional iterations of the MCMC chain

logical; should the new MCMC samples be added to the existing samples (TRUE; default) or replace them? If samples are added the arguments monitor_params and thin are ignored.

thin

thinning interval (see window.mcmc); ignored when add = TRUE.

monitor_params

named list or vector specifying which parameters should be monitored. For details, see *_imp and the vignette Parameter Selection. Ignored when add = TRUE.

progress.bar

character string specifying the type of progress bar. Possible values are "text" (default), "gui", and "none" (see update). Note: when sampling is performed in parallel it is not possible to display a progress bar.

mess

logical; should messages be given? Default is TRUE.

*_imp

The vignette Parameter Selection contains some examples on how to specify the argument monitor_params.

## Examples

# Example 1:
# Run an initial JointAI model:
mod <- lm_imp(y ~ C1 + C2, data = wideDF, n.iter = 100)

# Continue sampling: