Software required for "Boot Camp" in wildlife study design and data analysis


If you are using a computer which belongs to your organisation and you have to get your IT colleagues to install the software for the workshop please ask them to go to either http://bcss.org.my/software/ or http://bcssmalaysia.org.my/software/ (they should be identical).

Participants are asked to bring a laptop computer to the workshop.

Windows (7, 8 or 10), Mac (El Capitan or later), or Ubuntu (Trusty or Xenial or Bionic) all work. Other Linux distros should also work, but we have not tried. Our code has been most thoroughly tested on Windows machines.

They will need the following applications installed:

  • R statistical software, version 3.5.0 or later; see below.
  • JAGS application, version 4.2.0 or later; see below.
  • A spreadsheet application capable of handling CSV files (which I think all can).
  • A PDF reader which allows the file to be annotated, eg, with 'stickies'.

Your operating system

Windows: Everything usually works fine out of the box on Windows 7 or later (NOT on Windows XP or Vista).

On recent versions of Windows, the path to the userís Documents directory is typically C:/Users/<username>/Documents and the temporary directory is at C:/Users/<username>/AppData/Local/Temp. We have had issues with certain R functions where
   1. the userís area was configured on a network drive, even though the actual location was on the local machine;
   2. the <username> included CJK (Chinese-Japanese-Korean) characters.

After installing R, you can check this by running

tempdir() ; Sys.getenv("R_USER")

If "\\\\" or "//" or non-Western characters or unicode hex values (eg, <U+611B>) appear in the output, some R functions will fail.

Please ensure that the set up is typical with all-ascii characters in the path; if necessary, please set up a new user account for use during the workshop. Alternatively, use the workaround described here.

Apple Mac OS X: The latest versions of R and JAGS are only available for 10.11 (El Capitan) or later. If you have an earlier version, please upgrade.

Old versions which run on 10.6 Ė 10.10 are still available for download, but they are not compatible with other packages we need to run.

You will need the XQuartz utility; install this if necessary.

Ubuntu and other Linux distros: R 3.3.0 and above are no longer supported for Ubuntu 12.04 (Precise); only LTS versions are supported; see this blog post for information on installing R 3.5 on Bionic.

The versions of R and JAGS on the official repositories are not up to date, and may not even be cross-compatible. If you use Ubuntu, go here for a method to install R and JAGS and the rjags package, ensuring compatibility. For other distros, please check the installation instructions on the R and JAGS web sites (links below).

R statistical software:

This is free, open-source software. It works across all platforms.

If you have a version prior to 3.5.0, please update. Version 3.6.0 was released on 23 April 2019.

If you have version 3.5.x and can't upgrade, that's ok, but you may not be able to get the latest versions of add-in packages. If you have 3.4.x, please upgrade to 3.5.3: 3.5.x uses a different C++ compiler and new packages may not work on earlier versions of R.

Uninstall the old version before installing the new version. (On Windows, you can have multiple versions installed, but the user will run into compatibility issues if they start an old version by mistake.)

Downloads are available for Windows and Mac OS X El Capitan or later. For Ubuntu, see here for a quick way to install both R and JAGS. For other Linux distros, instructions are here.

Mac users may get a slew of warnings when they open R, eg, Setting LC_CTYPE failed, using "C". These need to be fixed or packages will not load! See the help topic referenced in the warning message or go here.

Firewalls: For parallel processing, R uses sockets to communicate between processes running on different cores; this usually causes a firewall window to pop up the first time it is used. You need to "Allow access" for R to private networks.


This is also free, open-source software which works across all platforms. If you have a version prior to 4.2.0, please uninstall and install the new version (currently 4.3.0).

All operating systems: look for the latest version download link just below the menu bar here. If that is not the version you want, use the links further down the page. Completely uninstall the old version of JAGS first.

Windows: Version 4.3.0 resolves compatibility issues with different R versions that were a problem with 4.2.0.

Mac: Downloads for Mac OS X (Mavericks or later) are here.

Linux: For Ubuntu, see here. For other Linux distros, go here and look at the Downloads section at the end; there's info on installing from source here.

JAGS does not appear in the Applications lists on Macs or Ubuntu. To check that it is installed properly and to see the version, open the Terminal and type "jags".

After installing R and JAGS, install the rjags package in R (see below) and check that you can load it without errors.

R packages

Installation of R packages (aka add-ins aka plug-ins) does not require administrator privileges. They are stored in the user's area (Windows default: C:/Users/<username>/Documents/R/win-library). The packages we need are available from CRAN and can be installed over the internet from within R.

The procedure is the same for all platforms.

rjags package: Open R and type (or copy-paste)


and press Enter/Return. A box may pop up asking about personal libraries: click Yes. You will need to select a mirror web site near you, or choose 0-cloud, which is a world-wide network.

If you get a message asking "Do you want to install from sources...", just click No or type "n" and press enter.

Check everything works! Open R and load rjags with


You should get a message saying "Linked to JAGS 4.x.x". If you get an error message, the most likely cause is a mismatch between the versions of JAGS and rjags; current versions of rjags (4-6 or later) need JAGS version 4.0.0 or later. On Mac and Linux systems, mysterious errors arise if components of JAGS 3 are still on the system.

Other R packages: Open R and copy/paste the following line into the Console:

install.packages(c("wiqid", "shiny", "secr", "beeswarm", "jagsUI"))

If you get a message asking "Do you want to install from sources...", just click No or type "n" and press enter. (This arises when source code for a new version is uploaded to CRAN but the binaries have not yet been updated.)

Many other packages on which the above four depend will also be downloaded and installed, 18MB in all.

If you have problems installing R packages, don't worry: we can fix this at the beginning of the workshop.


If you have suggestions, comments or questions about installing the software needed for the workshop please email stats.bcss@gmail.com.


Page updated 2 May 2019 by Mike Meredith