Simple mcmc example. In this model the target distribution is an
n dimensional multivariate normal with zero correlations. The
sampler will take a step from a uniform distribution with a width
w[i] * 2
.
1 | mcmc_example(x0, w, nsteps, pars)
|
x0 |
Initial point |
w |
Propopsal widths (uniform distribution) |
nsteps |
Number of steps |
pars |
Parameters (means and standard deviations) |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.