trinker / qdap

Quantitative Discourse Analysis Package: Bridging the gap between qualitative data and quantitative analysis
http://cran.us.r-project.org/web/packages/qdap/index.html
175 stars 44 forks source link

Cannot install qdap on RStudio #261

Open vivvi87 opened 3 years ago

vivvi87 commented 3 years ago

Hi ! I am trying to install the package but running into the following message when I load it:

 install.packages("qdap")
trying URL 'https://cran.rstudio.com/bin/macosx/el-capitan/contrib/3.6/qdap_2.4.3.tgz'
Content type 'application/x-gzip' length 3619579 bytes (3.5 MB)
==================================================
downloaded 3.5 MB

The downloaded binary packages are in
    /var/folders/5s/4czgwp8s0m7d6nz_d0vqtctr0000gn/T//RtmpkMMW62/downloaded_packages
> library(qdap)
Unable to find any JVMs matching version "(null)".
No Java runtime present, try --request to install.
Error: package or namespace load failed for ‘qdap’:
 .onLoad failed in loadNamespace() for 'rJava', details:
  call: fun(libname, pkgname)
  error: JVM could not be found
In addition: Warning messages:
1: package ‘qdap’ was built under R version 3.6.2 
2: In system("/usr/libexec/java_home", intern = TRUE) :
  running command '/usr/libexec/java_home' had status 1
3: In fun(libname, pkgname) :
  Cannot find JVM library 'NA/lib/server/libjvm.dylib'
Install Java and/or check JAVA_HOME (if in doubt, do NOT set it, it will be detected)

I have found some possible solutions online but no one of them seems to work (also it seems like none of the person who had a similar problem had the same error message as I get). Any suggestion? Thanks !

SivuyileNzimeni commented 3 years ago

You may encounter this error when R is cannot find JAVA _HOME on your system. You can download Oracle Java installation guide here. Once the installation is done, you may need to restart RStudio to install the package.