Another question: how do I ensure rJava is bytecode-compiled? I seem
to re-install the package with setting compilePKGS(T) before i install
it again, but most of rJava functions however seem to come back still
as not bytecode-compiled.
Thank you in advance.
-dmitriy
On Fri, Mar 16, 2012 at 3:48 P
The "low level" seems to be much-much better though... not sure why
the difference would be so fundamental...
f <- function() system.time( for( i in 1:1000)
.jcall("java/lang/Math", returnSig="D", "abs", as.numeric(i) ) )
> f()
user system elapsed
0.080 0.000 0.083
On Fri, Mar 16, 2012
PS caching reference to the class doesn't change anything fundamentally:
clazz <- J("java.lang.Double")
system.time( for( i in 1:1000) clazz$ parseDouble(as.character(i)))
user system elapsed
3.788 0.000 3.790
Java parsing is slow??? nope, still looking pretty appalling for what it does
Hello,
I am getting pretty poor rJava call performance
> system.time(for (i in 1:1000)
> J("java.lang.Double")$parseDouble(as.character(i)))
user system elapsed
4.884 0.000 4.900
i.e. 5 milliseconds per very simple call on a very fast cpu. JNI calls
themselves are said to be pretty
4 matches
Mail list logo