View source: R/mcmcOutput_constructor.R
mcmcOutput-class | R Documentation |
mcmcOutput
Convert output containing MCMC chains to the class mcmcOutput
. The function is generic, with methods for a range of input objects.
print
, summary
, plot
and window
methods are available for the class. See also postPlot
, discrepancyPlot
, crosscorrPlot
, postPriorOverlap
.
mcmcOutput(object, ...) ## Default S3 method: mcmcOutput(object, ...) ## S3 method for class 'mcmc.list' mcmcOutput(object, header, ...) ## S3 method for class 'mcmc' mcmcOutput(object, header, ...) ## S3 method for class 'jagsUI' mcmcOutput(object, header, ...) ## S3 method for class 'bugs' mcmcOutput(object, header, ...) ## S3 method for class 'rjags' mcmcOutput(object, header, ...) ## S3 method for class 'runjags' mcmcOutput(object, header, ...) ## S3 method for class 'matrix' mcmcOutput(object, nChains=1, header, ...) ## S3 method for class 'data.frame' mcmcOutput(object, nChains=1, header, ...)
object |
an object containing the MCMC chains; see Details. |
header |
text to use as the header by |
nChains |
the number of chains. |
... |
named arguments to be passed to other methods (currently not used). |
mcmcOutput
objects store the output from MCMC estimation runs in a compact and easily accessible format. Several customised extraction methods are available:
$ | : extracts arrays for individual parameters in the same way as a sims.list . |
[ with 1 index | : returns a new mcmcOutput object with the selected node(s). |
[ with 2 indices | : returns the selected row(s) and columns(s). |
[ with 3 indices | : behaves as an iterations x chains x nodes array. |
An object of class mcmcOutput
. This is a matrix with a column for the MCMC chain for each node monitored. The first 2 attributes in the list below must be present, the rest are optional but may be used by print
or summary
methods:
nChains | the number of chains. |
simsList | a list specifying which columns correspond to each parameter. |
header | text to be displayed as the first line when the object is printed. |
call | the original function call. |
modelFile | the name of the original model file. |
timeTaken | the time taken in seconds for the MCMC run. |
runDate | an object of class POSIXct with the date of the MCMC run. |
Mike Meredith.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.