Skip to content
Prev 257885 / 398502 Next

Using Java methods in R

I added this R code to the bottom of the previous code and it doesn't work
[[1]]
[1] "Java-Array-Object[D:[D at 8813f2"

[[2]]
[1] "Java-Array-Object[D:[D at 1d58aae"

[[3]]
[1] "Java-Array-Object[D:[D at 83cc67"
Error in print(ar34Ret(i, j), digits = 15) : 
  could not find function "ar34Ret"
The Java code is:
public final static double[][] arReturnTEST() { 
  double[][]retArr=new double[3][4]; for(int i=0;i<3;i++)for(int
j=0;j<4;j++)retArr[i][j]=i*1000+j; return(retArr); 
} 
R doesn't know how to print the array in the next to final line,
and thinks the array is a function in the final line.

Any suggestions?


--
View this message in context: http://r.789695.n4.nabble.com/Using-Java-methods-in-R-tp3469299p3472308.html
Sent from the R help mailing list archive at Nabble.com.