title: Installing rjags in R on OSX Mavericks
body: <p>I am trying to install the package "rjags" in R but am running into the following error:</p>
  
  <pre><code>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
  </code></pre>
  
  <p>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 <code>devtools</code> package, as recommended by this <a href="https://gist.github.com/casallas/8411082" rel="nofollow">site</a>:</p>
  
  <pre><code>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'
                              "
                        )
  </code></pre>
  
  <p>I've also gone through the instructions on this <a href="https://martynplummer.wordpress.com/2014/09/08/jags-3-4-0-for-mavericks/" rel="nofollow">other site</a> , 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!</p>