Installing R and JAGS on Ubuntu OS
I recently tried installing R and JAGS on my machine running
Ubuntu. I wanted to test my |
I already had R and JAGS 3 installed, together with
I was running the Long Term Support (LTS) version of Ubuntu, Trusty, so decided to upgrade to the latest, Wily, before going further, but I found that crashed regularly, so reinstalled Trusty. At this point I had a clean OS install.
The simplest way to install R, JAGS and
Update 9 Aug 2017: With a fresh install of Ubuntu
16.04.3 LTS (Xenial), I ran the above 3 lines, then in R
If you already have JAGS 3 installed
I actually tried to install JAGS 4 on the machine before
reinstalling Ubuntu. On Windows, JAGS 4 is installed in a
separate folder to JAGS 3, so you can happily have both on your
machine and both old and new versions of
The apparent reason for this was components of JAGS 3 which had not been removed when JAGS 4 was installed, as explained by Martyn Plummer here. So I uninstalled and purged, and then checked for remaining files:
I still had stuff in /usr/local/lib, so navigated to there and manually deleted the JAGS directory and all the jagslib* files (with sudo rm -r as they are read-only). Then reinstalled JAGS 4 from Michael Rutter's PPA and it all worked.
With Trusty, I downloaded the latest version of RStudio from their download page and opened it with Ubuntu Software Center, and that worked out of the box.
Update 9 Aug 2017: With Xenial, that didn't work; I needed to install libjpeg62 first. I failed to do that with apt-get, so downloaded the libjpeg62 installer from packages.ubuntu.com and the RStudio installer as above, then did:
That gave me the names of the installers that I could copy/paste into the following commands:
Once that was done, I could run RStudio normally.
| Updated 9 Aug 2017 by Mike Meredith|