GeneralModel-class | R Documentation |
This is the general model class, from which all other specific models for
involving BUGS (the software) for computing result.
It inherits all slots from AllModels
The datamodel
must obey the convention that the data input is
called exactly as in the corresponding data class.
All prior distributions for parameters should be contained in the
model function priormodel
. The background is that this can
be used to simulate from the prior distribution, before obtaining any
data.
datamodel
a function representing the BUGS data model specification (see the details above)
priormodel
a function representing the BUGS prior specification (see the details above)
modelspecs
a function computing the list of the data model and prior model specifications that are required for fully specifying them (e.g. prior parameters, reference dose, etc.), based on the data slots that are then required as arguments of this function. This will then be passed to BUGS for the computations.
init
a function computing the list of starting values for parameters required to be initialized in the MCMC sampler, based on the data slots that are then required as arguments of this function
sample
names of all parameters from which you would like to save the MCMC samples.
Model
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.