This file contains a description of files required to replicate the results presented in the article titled Hierarchical model for forecasting the outcomes of binary referenda All files are to be put in a working directory. The folder contains: readme.txt - file descriptions data_mcmc_ref.R - code required to read in, clean and prepare data required for simulations model3.bug - JAGS (rjags) model file, to be read when running simulations from within the data_mcmc_ref.R file modelSC2.odc - OpenBUGS file; to be used in OpenBUGS 3.2.3; contains code, data and expert opinions used for computation (Scottish referendum) refEU.csv - data on EU membership referendum (obtained from http://ukpollingreport.co.uk/eu-referendum; last accessed on 8 September 2017). refSC.csv - data on Scottish independence referendum (obtained from http://ukpollingreport.co.uk/scottish-independence-referendum; accessed last on 22 September 2014).