r-causal
r-causal copied to clipboard
Problem setting up r-causal
@chirayukong
Hi, this problem came from Peter Spirtes, through the Helpdesk:
I tried to follow the instructions for using r-causal but I could not get it to work.
install.packages("stringr")
install.packages("rJava”)
library(devtools)
install_github("bd2kccd/r-causal")
Downloading GitHub repo bd2kccd/r-causal@master
from URL https://api.github.com/repos/bd2kccd/r-causal/zipball/master
Installing rcausal
'/Library/Frameworks/R.framework/Resources/bin/R' --no-site-file --no-environ --no-save --no-restore --quiet CMD
INSTALL
'/private/var/folders/ph/2js0sw_j4sd01tbfb72gm5hw0000gp/T/RtmpZOcbT1/devtools1e22f624572/bd2kccd-r-causal-7c5be55'
--library='/Library/Frameworks/R.framework/Versions/3.4/Resources/library' --install-tests
- installing source package ‘rcausal’ ... ** R ** data ** inst ** preparing package for lazy loading Error : .onLoad failed in loadNamespace() for 'rJava', details: call: dyn.load(file, DLLpath = DLLpath, ...) error: unable to load shared object '/Library/Frameworks/R.framework/Versions/3.4/Resources/library/rJava/libs/rJava.so': dlopen(/Library/Frameworks/R.framework/Versions/3.4/Resources/library/rJava/libs/rJava.so, 6): Library not loaded: @rpath/libjvm.dylib Referenced from: /Library/Frameworks/R.framework/Versions/3.4/Resources/library/rJava/libs/rJava.so Reason: image not found ERROR: lazy loading failed for package ‘rcausal’
- removing ‘/Library/Frameworks/R.framework/Versions/3.4/Resources/library/rcausal’ Installation failed: Command failed (1)
In addition, when I tried to add the libraries “rJava” using the library command, it said it couldn’t find it.