MCMC-sampling from a posterior distribution of a P(OU)MM model given tree, values at the tips and a prior distribution
mcmcPOUMMGivenPriorTreeVTips(
loglik,
fitML = NULL,
parMapping,
parInitMCMC,
parPriorMCMC,
parScaleMCMC,
nSamplesMCMC,
nAdaptMCMC,
thinMCMC,
accRateMCMC,
gammaMCMC,
nChainsMCMC,
samplePriorMCMC,
pruneInfo,
...,
verbose = FALSE,
parallelMCMC = FALSE
)
a log-likelihood function.
an object returned by the maxLikPOUMMGivenTreeVTips
a function(numeric-vector) transforming a sampled vector on the scale of the parameters alpha, theta, sigma, sigmae and g0.
a function(chainNumber) returning the starting point of the MCMC as a vector.
a function(numeric-vector) returning the log-prior of the supplied vector
numeric matrix indicating the initial jump-distribution matrix
integer indicating how many iterations should the mcmc-chain contain
integer indicating how many initial iterations should be used for adaptation of the jump-distribution matrix
integer indicating the thinning interval of the mcmc-chain
(MCMC) numeric between 0 and 1 indicating the target acceptance rate Passed on to adaptMCMC::MCMC.
(MCMC) controls the speed of adaption. Should be in the interval (0.5,1]. A lower gammaMCMC leads to faster adaption. Passed on to adaptMCMC::MCMC.
integer indicating the number of chains to run. Defaults to 1.
logical indicating if only the prior distribution should be sampled. This can be useful to compare with mcmc-runs for an overlap between prior and posterior distributions.
a list-object returned from the pruneTree(tree, z) function.
Additional arguments. Currently not used except for the following: If ... includes debug = TRUE, some debug messages will be written also outside of the call to loglik.
Logical indicating if some informal messages should be written during run. This parameter is passed to loglik.
Logical indicating if chains should be run in parallel.
a list of coda objects
Currently, this function calls the MCMC function from the adaptMCMC package.