Displaying 14 results from an estimated 14 matches for "asdoubles".
2017 Oct 27
4
Cannot Compute Box's M (Three Days Trying...)
...quot; +
"6.2,3.4,5.4,2.3,virginica\n" +
"5.9,3,5.1,1.8,virginica\n";
List tableRead = rConnection.eval(
"read.csv(textConnection(\"" + inputIris + "\"), header = FALSE)").asList(); // works!
double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
String[] d5 = ((REXPVector) ((RList) tableRead).get(4)).asStrings();
// create data fram...
2017 Oct 28
2
Cannot Compute Box's M (Three Days Trying...)
Hey Duncan,
Hard to debug? That's an understatement. Eyes bleeding....
In any case, I tried all your suggestions. To get "integer" for the final column, I had to change the code to get integers instead of strings.
double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
int[] d5 = ((REXPVector) ((RList) tableRead).get(4)).asIntegers();
// create data frame...
2017 Oct 28
2
Cannot Compute Box's M (Three Days Trying...)
...irginica\n" +
>> "5.9,3,5.1,1.8,virginica\n";
>> List tableRead = rConnection.eval(
>> "read.csv(textConnection("" + inputIris + ""), header = FALSE)").asList(); // works!
>> double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
>> double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
>> double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
>> double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
>> String[] d5 = ((REXPVector) ((RList) tableRead).get(4...
2017 Oct 28
2
Cannot Compute Box's M (Three Days Trying...)
...t; "5.9,3,5.1,1.8,virginica\n";
>>> List tableRead = rConnection.eval(
>>> "read.csv(textConnection("" + inputIris + ""), header =
>>> FALSE)").asList(); // works!
>>> double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
>>> double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
>>> double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
>>> double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
>>> String[] d5 = ((REXPVector) ((RList)...
2017 Oct 28
0
Cannot Compute Box's M (Three Days Trying...)
...ger vector with an attribute listing the levels. Using
strings instead can cause problems in a few R functions (they want
factors, and don't do automatic conversions), but the errors you're
seeing seem more fundamental.
>
> double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
> double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
> double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
> double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
> *int**[] d5 = ((REXPVector) ((RList) tableRead).get(**4**)).asInteger...
2017 Oct 29
2
Cannot Compute Box's M (Three Days Trying...)
...ttribute listing the levels. Using
>> strings instead can cause problems in a few R functions (they want
>> factors, and don't do automatic conversions), but the errors you're
>> seeing seem more fundamental.
>> double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
>> double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
>> double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
>> double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
>> int*[] d5 = ((REXPVector) ((RList) tableRead).get(4))...
2017 Oct 27
0
Cannot Compute Box's M (Three Days Trying...)
...virginica\n" +
> "5.9,3,5.1,1.8,virginica\n";
>
> List tableRead = rConnection.eval(
> "read.csv(textConnection(\"" + inputIris + "\"), header = FALSE)").asList(); // works!
>
> double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
> double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
> double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
> double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
> String[] d5 = ((REXPVector) ((RList) tableRead).get(4)).asStrings();...
2017 Oct 29
0
Cannot Compute Box's M (Three Days Trying...)
...the levels. Using
>> strings instead can cause problems in a few R functions (they want
>> factors, and don't do automatic conversions), but the errors you're
>> seeing seem more fundamental.
>> double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
>> double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
>> double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
>> double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
>> /int/*[] d5 = ((REXPVector) ((RList)...
2017 Oct 27
0
Cannot Compute Box's M (Three Days Trying...)
...ginica\n" +
> "5.9,3,5.1,1.8,virginica\n";
>
> List tableRead = rConnection.eval(
> "read.csv(textConnection(\"" + inputIris + "\"), header =
> FALSE)").asList(); // works!
>
> double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
> double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
> double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
> double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
> String[] d5 = ((REXPVector) ((RList) tableRead).get(4)).asStrings();...
2017 Oct 28
0
Cannot Compute Box's M (Three Days Trying...)
..."5.9,3,5.1,1.8,virginica\n";
>> List tableRead = rConnection.eval(
>> "read.csv(textConnection("" + inputIris + ""), header =
>> FALSE)").asList(); // works!
>> double[] d1 = ((REXPVector) ((RList) tableRead).get(0)).asDoubles();
>> double[] d2 = ((REXPVector) ((RList) tableRead).get(1)).asDoubles();
>> double[] d3 = ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
>> double[] d4 = ((REXPVector) ((RList) tableRead).get(3)).asDoubles();
>> String[] d5 = ((REXPVector) ((RList)...
2017 Oct 26
1
How to create a table structure in Java code?
Thanks! I just figured it out (thanks to "Beyond Compare") and was coming here to post back.
The boxM test doesn't work with that (now, finally working) REXP structure, but I probably now need to create a table or something and parse that structure.
So much fun! :)
Thanks again.
- M
Sent from [ProtonMail](https://protonmail.com), Swiss-based encrypted email.
> --------
2017 Oct 28
0
Cannot Compute Box's M (Three Days Trying...)
....1,1.8,virginica\n";
>> List tableRead = rConnection.eval( "read.csv(textConnection(""
>> + inputIris + ""), header = FALSE)").asList(); // works!
>> double[] d1 = ((REXPVector) ((RList)
>> tableRead).get(0)).asDoubles(); double[] d2 = ((REXPVector)
>> ((RList) tableRead).get(1)).asDoubles(); double[] d3 =
>> ((REXPVector) ((RList) tableRead).get(2)).asDoubles();
>> double[] d4 = ((REXPVector) ((RList)
>> tableRead).get(3)).asDoubles(); String[] d5 = ((REXPV...
2009 Mar 11
1
RServe
Dear all,
I'm trying to use R-functions from Java. I want to use the Package Rserve.
Everthing is installed and I can run my Java-testprogramm.
...
Rconnection r = new Rconnection();
double[] d = r.eval("rnorm(10)").asDoubleArray();
...
But now I get always arrays with ten "0.0", which is not correct
I suppose, that is is a problem from R, because at the fist time (last
2005 Aug 22
1
Fetching Warning Messages
Hi,
I am facing one problem of fetching R warning messages in Java Code
using Rserve. It is easier to trap R Error messages by using catching
RSrvException. I came to know one way of fetching R Warning messages, i.e.
using "withCallingHandlers", below is my Java Program, which uses
withCallingHandlers of R :
import org.rosuda.JRclient.*;