Using JAGS and runjags
Although it's a bit silly to break out MCMC for the single-parameter career recommendation analysis that we discussed earlier, applying this method to this simple example will aid in its usage for more complicated models.
In order to get started, you need to install a software program called JAGS, which stands for Just Another Gibbs Sampler (a Gibbs sampler is a type of MCMC sampler). This program is independent of R, but we will be using R packages to communicate with it. After installing JAGS, you will need to install the R packages
modeest. As a reminder, you can install all three with this command:
> install.packages(c("rjags", "runjags", "modeest"))
To make sure everything is installed properly, load ...