This repository contains the analysis, figures, text and tables for the manuscript *Developing Constraint in Bayesian Mixed Models* submitted by Julia Haaf and Jeff Rouder.

The manuscript is written in RMarkdown using the following packages:
R (3.3.1, R Core Team, 2016) and the R-packages abind (1.4.3, Plate & Heiberger, 2015), BayesFactor (0.9.12.2, Morey & Rouder, 2015), coda (0.18.1, Plummer, Best, Cowles, & Vines, 2006), curl (0.9.7, Ooms, 2016), devtools (1.11.1, Wickham & Chang, 2016), fields (8.4.1, Douglas Nychka, Reinhard Furrer, John Paige, & Stephan Sain, 2015), gmm (1.5.2, Chaussé, 2010), maps (3.1.1, Richard A. Becker, Ray Brownrigg. Enhancements by Thomas P Minka, & Deckmyn., 2016), MASS (7.3.45, Venables & Ripley, 2002), Matrix (1.2.6, Bates & Maechler, 2016), MCMCpack (1.3.6, Martin, Quinn, & Park, 2011), msm (1.6.1, Jackson, 2011), mvtnorm (1.0.5, Genz & Bretz, 2009; Wilhelm & G, 2015), papaja (0.1.0.9074, Aust & Barth, 2015), plotrix (3.6.1, Lemon, 2006), sandwich (2.3.4, Zeileis, 2004, 2006), spam (1.3.0, Furrer & Sain, 2010; Gerber & Furrer, 2015), spatialfil (0.15, Dinapoli & Gatta, 2015), and tmvtnorm (1.4.10, Wilhelm & G, 2015)

Once the packages are installed you can simply open "papers/pmSubmitted/draft1.Rmd" and knit it. This will produce the manuscript exactly as we submitted it.

*NOTE:* Knitting the manuscript may take a while, because it generated new MCMC chains using the Bayes-foctor package for several data sets and models.