Fits a stan model using rstan::sampling
. Provides the optional ability to run chains using
future
with error catching, timeouts and merging of completed chains.
fit_model_with_nuts(
args,
future = FALSE,
max_execution_time = Inf,
id = "stan"
)
List of stan arguments
Logical, defaults to FALSE
. Should future
be used to run stan chains in parallel.
Numeric, defaults to Inf. What is the maximum execution time per chain in seconds. Results will still be returned as long as at least 2 chains complete successfully within the timelimit.
A character string used to assign logging information on error. Used by regional_epinow
to assign errors to regions. Alter the default to run with error catching.
A stan model object