Posts

Showing posts with the label Mac OS

Two-Step fix for rJava library installation on Mac OS

I've been using R for some time and over the years I've had one consistent nagging problem.  rJava Perhaps the single most temperamental library in the whole history of R. If you are like me, you likely try to avoid anything Java based, like using openxlsx  instead of xlsx . I don't use Java but a number of libraries I do use, have it as a dependency. For example, I like to use qdap because it has a lot of nice tools for qualitative analysis, which of course uses Java. The big problem is that rJava never installs properly and gives some error along the lines of not being able to find jdk files, jni.h, or Java home when you try to call the library. I have a couple quick steps here that can get rJava up and running quickly. I haven't noticed this issue in Windows which means the library is probably written for Windows and the developer hasn't bothered to make it function out-of-the-box on Mac OS. Two quick steps and you can get rJava working in R on Mac OS. Downloa...