summarizeMPT: Summarize JAGS Output for Hierarchical MPT Models

View source: R/summarizeMPT.R

summarizeMPTR Documentation

Summarize JAGS Output for Hierarchical MPT Models

Description

Provide clean and readable summary statistics tailored to MPT models based on the JAGS output.

Usage

summarizeMPT(mcmc, mptInfo, probs = c(0.025, 0.5, 0.975), summ = NULL)

Arguments

mcmc

the actual mcmc.list output of the sampler of a fitted MPT model (accesible via fittedModel$runjags$mcmc)

mptInfo

the internally stored information about the fitted MPT model (accesible via fittedModel$mptInfo)

probs

quantile probabilities used to compute credibility intervals

summ

optional argument for internal use

Details

The MPT-specific summary is computed directly after fitting a model. However, this function might be used manually after removing MCMC samples (e.g., extending the burnin period).

Examples

# Remove additional burnin samples and recompute MPT summary
## Not run: 
# start later or thin (see ?window)
mcmc.subsamp <- window(fittedModel$runjags$mcmc, start = 3001, thin = 2)
new.mpt.summary <- summarizeMPT(mcmc.subsamp, fittedModel$mptInfo)
new.mpt.summary

## End(Not run)

TreeBUGS documentation built on May 31, 2023, 9:21 p.m.