Hi, I'm new to R and trying to use xlsx. I can't get it to run - please see the below error message. I've tried to install a recent java version but it didn't seem to fix the problem. I am using 10.13.6 Mac High Sierra OS .Could anyone help? Thank you.
Error in library(xslx) : there is no package called ‘xslx’
trying URL 'http://cran.r-project.org/bin/macosx/el-capitan/contrib/3.6/xlsx_0.6.1.tgz'
Content type 'application/x-gzip' length 461752 bytes (450 KB)
downloaded 450 KB
The downloaded binary packages are in
Unable to find any JVMs matching version "(null)".
Error: package or namespace load failed for ‘xlsx’:
.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.6/Resources/library/rJava/libs/rJava.so':
dlopen(/Library/Frameworks/R.framework/Versions/3.6/Resources/library/rJava/libs/rJava.so, 6): Library not loaded: /Library/Java/JavaVirtualMachines/jdk-11.0.1.jdk/Contents/Home/lib/server/libjvm.dylib
Referenced from: /Library/Frameworks/R.framework/Versions/3.6/Resources/library/rJava/libs/rJava.so
Reason: image not found
In addition: Warning message:
In system("/usr/libexec/java_home", intern = TRUE) :
running command '/usr/libexec/java_home' had status 1
No Java runtime present, try --request to install.