I am trying to install the package "rjags" in R but am running into the following error:
Loading required package: rjags
Error : .onLoad failed in loadNamespace() for 'rjags', details:
call: dyn.load(file, DLLpath = DLLpath, ...)
error: unable to load shared object '/Library/Frameworks/R.framework/Versions/3.1/Resources/library/rjags/libs/rjags.so':
dlopen(/Library/Frameworks/R.framework/Versions/3.1/Resources/library/rjags/libs/rjags.so, 10): Symbol not found: __ZN5RangeC1ERKSt6vectorIiSaIiEES4_
Referenced from: /Library/Frameworks/R.framework/Versions/3.1/Resources/library/rjags/libs/rjags.so
Expected in: /usr/local/lib/libjags.3.dylib
in /Library/Frameworks/R.framework/Versions/3.1/Resources/library/rjags/libs/rjags.so
Error: package ‘rjags’ could not be loaded
I've installed JAGS on my Mac (running Mavericks), and I am running R-3.1.2. I've tried installing from the url using the devtools
package, as recommended by this site:
install_url("http://sourceforge.net/projects/mcmc-jags/files/rjags/3/rjags_3-2.tar.gz",
args="--configure-args='--with-jags-include=/Users/casallas/homebrew/opt/jags/include/JAGS
--with-jags-lib=/Users/casallas/homebrew/opt/jags/lib'
"
)
I've also gone through the instructions on this other site , trying the different versions of JAGS and receive the same error. I'm at a loss for what to try next and am sure the solution is simple. Does anyone have any insights? Thanks so much!