[R] JAGS 4.x, rjags 4.x problems | Linux

Evan Cooch evan.cooch at gmail.com
Wed Nov 4 21:36:01 CET 2015



On 11/4/2015 2:08 PM, Evan Cooch wrote:
> Greetings --
>
> This has also been posted on the jags forum, but since I suspect the 
> problem is more 'R-related' than jags, will aos post here.
>
> Decided to 'upgrade' from jags 3.x.x to 4.x.x today, on my GNU/Linux 
> boxes (which run latest RHEL). Here are the basic details:
>
> 1\ used R 3.2.2 compiled from source. 64-bit -- nothing fancy, other 
> than the fact that I used OpenBLAS instead of 'generic'. Works fine.
>
> 2\ downloaded and compiled JAGS 4.0.1 from source (nothing fancy, 
> ./configure & make & make install) -- no errors. Runs fine as a 
> standalone app from CLI.
>
>
> 3\ Downloaded rjags_4-3.tar.gz, and installed from R CLI (within R -- 
> usual R CMD INSTALL approach). Again, no errors reported.
>
>
> However, when I fire up R, and try something simple like
>
> library(R2jags)
>
> I get a whole slew of error messages - following is reproducible on 
> all my machines:
>
> Loading required package: rjags
> Loading required package: coda
> Error : .onLoad failed in loadNamespace() for 'rjags', details:
> call: dyn.load(file, DLLpath = DLLpath, ...)
> error: unable to load shared object 
> '/usr/lib64/R/library/rjags/libs/rjags.so':
> libjags.so.3: cannot open shared object file: No such file or directory
> Error: package ‘rjags’ could not be loaded
>
>

Further puzzlement -- I uninstalled R2jags and rjags, with the idea that 
re-installing them (ostensibly with the 'latest and greatest') would do 
the trick. While the process went fine for R2jags, when I tried to 
re-install rjags, got the following error messages:

checking for gcc -m64 -std=gnu99 option to accept ISO C89... none needed
checking for jags_version in -ljags... yes
checking version of JAGS library... wrong version
configure: error: rjags requires JAGS version 4.x.y
ERROR: configuration failed for package ‘rjags’
* removing ‘/usr/lib64/R/library/rjags’
* restoring previous ‘/usr/lib64/R/library/rjags’


I'm confused as to how it is not finding JAGS 4.x.y, which is not only 
most definitely on the system, but in the path:

[root at euler egc]# jags
Welcome to JAGS 4.0.1 on Wed Nov  4 15:35:12 2015
JAGS is free software and comes with ABSOLUTELY NO WARRANTY
Loading module: basemod: ok
Loading module: bugs: ok



More information about the R-help mailing list