Using R, the following error is returned:
java.lang.OutOfMemoryError: GC overhead limit exceeded
The default heap size for libraries that rely on rJava is 512MB. It is relatively easy to exceed this maximum size.
Increase the JVM heap size in rJava's options support:
options(java.parameters = "-Xmx1024m")
Note that this step must be performed prior to loading any packages.