How to set the class path of rjava in R?
•
Java
I have an R package that contains several jar files
In the main package, I have an onload function that uses The jpackage function starts the JVM According to the help, this function takes the "morepaths" parameter, and I provide the absolute paths of the two jar files But it won't work
I tried it, too
jar.one = paste(lib,pkg,"java","One.jar",sep=.Platform$file.sep) jar.two = paste(lib,"Two.jar",sep=.Platform$file.sep) .jinit(classpath=c(jar.one,jar.two))
In the onload function
Any hint would be appreciated, Martin
Solution
try. jaddClassPath
.jaddClassPath("blah.jar")
The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
二维码