Description Usage Arguments Details Value See Also Examples
Queries and sets options for JAGS analyses.
1 2 3 |
... |
options can be defined using |
The function opts_jagr()
, which can aso be invoked using its alias
options_jaggernaut()
, behaves just like the options()
function in the
base library, with the additional feature that
opts_jagr(mode="default")
will
reset all options to the values for the default mode.
There are six available modes: debug, explore, test and demo
report and paper.
In summary the debug model should be used when first trying to code models in the
JAGS dialect of the BUGS language. Once the JAGS code is running without errors
is now time to switch to the explore model to look at model adequacy. Once you are content
that the model is adequate you can now switch to report model to extract the results
for presentation in a report or paper model if you are going to be sending the results to
a peer-reviewed journal. The default mode is report mode. test and demo mode are used
internally when testing the package and running demos respectively.
Available options are
the credible interval level (default = 0.95)
the type ("mean" or "median") of the point estimate (default = "mean")
the number of MCMC chains (default = 3)
the number of times to resample until convergence is achieved (default = 3)
the total number of MCMC samples to thin from the second halves of the MCMC chains (default = 1000)
whether in parallel.
whether to suppress messages (default = FALSE)
the R-hat threshold for convergence (default = 1.1)
By default a JAGS analysis will retain a minumum of 1,000 MCMC samples
thinned from the second halves of three chains. For example
if niters = 1000
in the analysis then by default 334 samples will be
thinned from the last 500 iterations of each chain.
Convergence is considered to have been achieved when all the monitored
parameters have an R-hat less than the value of the convergence
option
which
by default is 1.1 (Kery & Schaub 2011). If the initial number of iterations
are performed and the convergence target has not been achieved and
nresample > 0
then the value of niters
is doubled, the MCMC sampling to date is
considered the burn in period, the saved MCMC samples are discarded and
MCMC sampling continues. This process is repeated until the convergence target is
achieved or resampling would exceed the value of the nresample
argument.
For opts_jagr()
a list of all jaggernaut options values
sorted by name. For opts_jagr(name)
a list of length one of the
option value. When setting one or more options a list with the previous values of
the options unchanged (returned invisibly).
jags_analysis
and options
1 2 3 4 5 6 7 8 9 10 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.