Description Usage Arguments Value See Also
Get residuals with estimates using derived code in a JAGS analysis
1 2 3 4 5 | ## S3 method for class 'jags_analysis'
residuals(object, parm = "residual",
model_id = default_model_id(object), derived_code = NULL,
random_effects = NULL, level = "current", estimate = "current",
data = NULL, ...)
|
object |
a jags_analysis object. |
parm |
a character element naming the derived parameter for which the estimates should be calculated by default = "residual" |
model_id |
a count or string specifying the jags model to select. |
derived_code |
a character element defining a block in the JAGS dialect of the BUGS language that defines one or more derived parameters for each row of data. If NULL derived_code is as defined by the JAGS model for which the JAGS analysis was performed. |
random_effects |
a named list which specifies which parameters to treat as random variables. If NULL random is as defined by the JAGS model for which the JAGS analysis was performed. |
level |
a numeric scalar specifying the significance level or a character
scalar specifying which mode the level should be taken from. By default the
level is as currently specified by |
estimate |
a character scalar specifying whether the point estimate should
be the "mean" or the "median" or a character scalar which mode the level should be
taken from. By default the
estimate is as currently specified by |
data |
the dataset for which to calculate the residuals. By default newdata is NULL as the residuals are typically calculated on the original dataset. |
... |
further arguments passed to or from other methods. |
the input data frame with the point estimate and credibility intervals for the residuals
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.