Note

This packages is no longer maintained. I cannot guarantee you can still get it running, nor help you with it.

MC2Pack

While working on diverse projects, I found myself rewriting simulation code over and over again. After a while, I started collecting chunks, which came to be MC2Pack, an Ox package for using MCMC sampling methods to construct a sample from a posterior density.

An earlier version of this package bore the name MCMCPack, though it was developped entirely independently from the work by Andrew Martin and Kevin Quinn on MCMCpack on R. To avoid confusion, the name of the Ox package was changed from MCMCPack to MC2Pack.

Implemented sampling methods

Implemented in the package are

Apart from sampling, the package can also provide estimates of the (logarithm of) the marginal likelihood of the model, a building block for the Bayes factor which contrasts models according to their fit to the data.

Documentation

The documentation of the package is available on the web, and also in PDF format in the article Markov Chain Monte Carlo methods: Implementation and comparison. This latter article is also included within the installation file.

As an example, the file mcstack.ox samples from a mixture model on stackloss data.

Download and installation instructions

Download the packages
mc2pack.zip MC2Pack itself
gnudraw6.zip GnuDraw
oxutils.zip OxUtils
and unzip them from your Ox main directory. MC2Pack depends on some files in the other packages, hence the larger installation procedure. If you want to use GnuDraw fully, also to view the graphs on screen instead of using OxMetrics, finish off the installation by getting a working version of GnuPlot; see also the installation instructions at the GnuDraw page.

To install the documentation on your computer, add the following lines

<tr><td><a href="../packages/gnudraw/doc/gnudraw7.html">Gnudraw Graphics</a></td></tr>
<tr><td><a href="../packages/oxutils/doc/oxutils.html">OxUtils</a></td></tr>
<tr><td><a href="../packages/mc2pack/doc/mc2pack.html">MC2Pack</a></td></tr>
to the file <ox-home>/doc/oxmenu.html, e.g. after the line pointing to the graphics reference.

This packages is no longer maintained. I cannot guarantee you can still get it running, nor help you with it.