plotConv {BMS} | R Documentation |
Plots the posterior model probabilites based on 1) marginal likelihoods and 2) MCMC frequencies for the best models in a 'bma' object and details the sampler's convergence by their correlation
plotConv(bmao, include.legend = TRUE, add.grid = TRUE, ...)
bmao |
an object of class 'bma' - see |
include.legend |
whether to include a |
add.grid |
whether to include a |
... |
other parameters for |
A call to bms with a MCMC sampler (e.g.
bms(datafls,mcmc="bd",nmodel=100)
uses a Metropolis-Hastings
algorithm to sample through the model space: the frequency of how often
models are drawn converges to the distribution of their posterior marginal
likelihoods.
While sampling, each 'bma' object stores the best models
encountered by its sampling chain with their marginal likelihood and their
MCMC frequencies.
plotConv
compares the MCMC frequencies to
marginal likelihoods, and thus visualizes how well the sampler has
converged.
plotConv
is also used by plot.bma
pmp.bma
for posterior model probabilites based on the
two concepts, bms
for creating objects of class 'bma'
Check http://bms.zeugner.eu for additional help.
data(datafls) mm=bms(datafls[,1:12],user.int=FALSE) plotConv(mm) #is similar to matplot(pmp.bma(mm),type="l")