Learn R Programming

numOSL (version 1.8)

reportSAM: Statistical age models' MCMC output reporting

Description

Summarizing distributions of parameters simulated from a statistical age model.

Usage

reportSAM(obj, burn = 10000, thin = 5, 
          plot = TRUE, outfile = NULL, ...)

Arguments

obj
required: an object of S3 class "mcAgeModels", which is produced by function mcFMM or mcMAM
burn
integer(with default): number of iterations (i.e., the initial, non-stationary portion of the chain) to be discarded
thin
integer(with default): take every thin-th iteration
plot
logical(with default): plot the MCMC output or not
outfile
character(optional): if specified, simulated parameters will be written to a file named "outfile" in ".csv" format and saved to the current work directory
...
do not use

Value

  • Return a list that contains the following elements:
  • parsparameters and relevant statistics
  • quantilequantiles of simulated parameters
  • maxlikcalculated maximum logged likelihood value

Details

Function reportSAM summarizes the output of a Markov chain (the mean values, the standard deviations, and the 95 percent confidence intervals). The initial i (burn=i) samples may have been affected by the inital state and has to be discarded ("burn-in"). Autocorrelation of simulated samples can be reduced by taking every j-th (thin=j) iteration ("thining").

References

Lunn D, Jackson C, Best N, Thomas A, Spiegelhalter D, 2013. The BUGS book: a practical introduction to bayesian analysis. Chapman & Hall/CRC Press.

Gelman A, Carlin JB, Stern HS, Dunson DB, Vehtari A, Rubin DB, 2013. Bayesian data analysis. Chapman & Hall/CRC Press.

See Also

mcFMM; mcMAM