getParam {TreeBUGS} | R Documentation |
Get Parameter Posterior Statistics
Description
Returns posterior statistics (e.g., mean, median) for the parameters of a hierarchical MPT model.
Usage
getParam(fittedModel, parameter = "mean", stat = "mean", file = NULL)
Arguments
fittedModel |
a fitted latent-trait MPT model (see
|
parameter |
which parameter(s) of the (hierarchical) MPT model should be
returned? (see details in |
stat |
whether to get the posterior |
file |
filename to export results in .csv format (e.g.,
|
Details
This function is a convenient way to get the information stored in
fittedModel$mcmc.summ
.
The latent-trait MPT includes the following parameters:
-
"mean"
(group means on probability scale) -
"mu"
(group means on probit scale) -
"sigma"
(SD on probit scale) -
"rho"
(correlations on probit scale) -
"theta"
(individual MPT parameters)
The beta MPT includes the following parameters:
-
"mean"
(group means on probability scale) -
"sd"
(SD on probability scale) -
"alph"
,"bet"
(group parameters of beta distribution) -
"theta"
(individual MPT parameters)
Author(s)
Daniel Heck
See Also
getGroupMeans
mean group estimates
Examples
## Not run:
# mean estimates per person:
getParam(fittedModel, parameter = "theta")
# save summary of individual estimates:
getParam(fittedModel,
parameter = "theta",
stat = "summary", file = "ind_summ.csv"
)
## End(Not run)