Update the model in adaptive mode.
adapt(object, n.iter, end.adaptation=FALSE, ...)
length of the adaptive phase
logical flag. If
additional arguments to the update method
This function is not normally called by the user. It is called by the
jags.model function when the model object is created.
When a JAGS model is compiled, it may require an initial sampling phase during which the samplers adapt their behaviour to maximize their efficiency (e.g. a Metropolis-Hastings random walk algorithm may change its step size). The sequence of samples generated during this adaptive phase is not a Markov chain, and therefore may not be used for posterior inference on the model.
adapt function updates the model for
iterations in adaptive mode. Then each sampler reports whether it
has acheived optimal performance (e.g. whether the rejection rate of a
Metropolis-Hasting sampler is close to the theoretical optimum). If
any sampler reports failure of this test then
end.adaptation = TRUE, then adaptive mode is turned off on
exit, and further calls to
adapt() do nothing. The model may be
maintained in adaptive mode with the default option
FALSE so that successive calls to
adapt() may be made until
adaptation is satisfactory.
TRUE if all the samplers in the model have successfully
adapted their behaviour to optimum performance and
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.