When installing rJava using the install.packages(\"rJava\") command I get the following error:
checking Java support in R... present:
interprete
I've encountered similar problem on Ubuntu 16.04 and was able to solve it by creating a folder named "default-java" in /usr/lib/jvm and copying into it all the contents of the /usr/lib/jvm/java-8-oracle. I opted for this solution as correcting JAVA_HOME environment variable turned out to be of no use.