Examples of asDoubleMatrix()


Examples of org.rosuda.REngine.REXP.asDoubleMatrix()

      String script = "normalized <- t(as.matrix(sapply(data, function(x) {(x - min(x, na.rm=TRUE))/(max(x, na.rm=TRUE)- min(x, na.rm=TRUE))})))";
     
      rConnection.eval(script);
     
      REXP evalValue = rConnection.eval("normalized");
      result = evalValue.asDoubleMatrix();
    }

    catch (Exception e)
    {
      e.printStackTrace();
View Full Code Here

Examples of org.rosuda.REngine.REXP.asDoubleMatrix()

            kClusteringResult[i] = new RResult(name, evalValue.asIntegers());
          else if (evalValue instanceof REXPDouble){
            if (evalValue.dim() == null)
              kClusteringResult[i] = new RResult(name, evalValue.asDoubles());
            else
              kClusteringResult[i] = new RResult(name, evalValue.asDoubleMatrix());
          }
          else{
            // if no previous cases were true, return debug String
            kClusteringResult[i] = new RResult(name, evalValue.toDebugString());
          }
View Full Code Here

Examples of org.rosuda.REngine.REXP.asDoubleMatrix()

            mdResult[i] = new RResult(name, evalValue.asIntegers());
          else if (evalValue instanceof REXPDouble){
            if (evalValue.dim() == null)
              mdResult[i] = new RResult(name, evalValue.asDoubles());
            else
              mdResult[i] = new RResult(name, evalValue.asDoubleMatrix());
          }
          else{
            // if no previous cases were true, return debug String
            mdResult[i] = new RResult(name, evalValue.toDebugString());
          }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.