Package org.rosuda.JRI

Examples of org.rosuda.JRI.Rengine.eval()


      // Initialize.
      rEngine.eval("mz <- " + mz, false);
      rEngine.eval("numPoints <- length(intensity)", false);

      // Construct xcmsRaw object
      rEngine.eval("xRaw <- new(\"xcmsRaw\")", false);
      rEngine.eval("xRaw@tic <- intensity", false);
      rEngine.eval("xRaw@scantime <- scantime * " + SECONDS_PER_MINUTE,
          false);
      rEngine.eval("xRaw@scanindex <- 1:numPoints", false);
      rEngine.eval("xRaw@env$mz <- rep(mz, numPoints)", false);
View Full Code Here


      rEngine.eval("mz <- " + mz, false);
      rEngine.eval("numPoints <- length(intensity)", false);

      // Construct xcmsRaw object
      rEngine.eval("xRaw <- new(\"xcmsRaw\")", false);
      rEngine.eval("xRaw@tic <- intensity", false);
      rEngine.eval("xRaw@scantime <- scantime * " + SECONDS_PER_MINUTE,
          false);
      rEngine.eval("xRaw@scanindex <- 1:numPoints", false);
      rEngine.eval("xRaw@env$mz <- rep(mz, numPoints)", false);
      rEngine.eval("xRaw@env$intensity <- intensity", false);
View Full Code Here

      rEngine.eval("numPoints <- length(intensity)", false);

      // Construct xcmsRaw object
      rEngine.eval("xRaw <- new(\"xcmsRaw\")", false);
      rEngine.eval("xRaw@tic <- intensity", false);
      rEngine.eval("xRaw@scantime <- scantime * " + SECONDS_PER_MINUTE,
          false);
      rEngine.eval("xRaw@scanindex <- 1:numPoints", false);
      rEngine.eval("xRaw@env$mz <- rep(mz, numPoints)", false);
      rEngine.eval("xRaw@env$intensity <- intensity", false);

View Full Code Here

      // Construct xcmsRaw object
      rEngine.eval("xRaw <- new(\"xcmsRaw\")", false);
      rEngine.eval("xRaw@tic <- intensity", false);
      rEngine.eval("xRaw@scantime <- scantime * " + SECONDS_PER_MINUTE,
          false);
      rEngine.eval("xRaw@scanindex <- 1:numPoints", false);
      rEngine.eval("xRaw@env$mz <- rep(mz, numPoints)", false);
      rEngine.eval("xRaw@env$intensity <- intensity", false);

      // Construct ROIs.
      rEngine.eval("ROIs <- list()", false);
View Full Code Here

      rEngine.eval("xRaw <- new(\"xcmsRaw\")", false);
      rEngine.eval("xRaw@tic <- intensity", false);
      rEngine.eval("xRaw@scantime <- scantime * " + SECONDS_PER_MINUTE,
          false);
      rEngine.eval("xRaw@scanindex <- 1:numPoints", false);
      rEngine.eval("xRaw@env$mz <- rep(mz, numPoints)", false);
      rEngine.eval("xRaw@env$intensity <- intensity", false);

      // Construct ROIs.
      rEngine.eval("ROIs <- list()", false);
      int roi = 1;
View Full Code Here

      rEngine.eval("xRaw@tic <- intensity", false);
      rEngine.eval("xRaw@scantime <- scantime * " + SECONDS_PER_MINUTE,
          false);
      rEngine.eval("xRaw@scanindex <- 1:numPoints", false);
      rEngine.eval("xRaw@env$mz <- rep(mz, numPoints)", false);
      rEngine.eval("xRaw@env$intensity <- intensity", false);

      // Construct ROIs.
      rEngine.eval("ROIs <- list()", false);
      int roi = 1;
      for (int start = 0; start < intensity.length; start++) {
View Full Code Here

      rEngine.eval("xRaw@scanindex <- 1:numPoints", false);
      rEngine.eval("xRaw@env$mz <- rep(mz, numPoints)", false);
      rEngine.eval("xRaw@env$intensity <- intensity", false);

      // Construct ROIs.
      rEngine.eval("ROIs <- list()", false);
      int roi = 1;
      for (int start = 0; start < intensity.length; start++) {

        // Found non-zero section.
        if (intensity[start] > 0.0) {
View Full Code Here

            end++;
          }

          // Add ROI to list.
          rEngine.eval("ROIs[[" + roi + "]] <- list('scmin'="
              + (start + 1) + ", 'scmax'=" + end
              + ", 'mzmin'=mz, 'mzmax'=mz)", false);

          // Next ROI.
          start = end;
View Full Code Here

      }

      // Do peak picking.
      final REXP centWave = roi <= 1
          ? null
          : rEngine
              .eval("findPeaks.centWave(xRaw, ppm=0, mzdiff=0, verbose=TRUE"
                  + ", peakwidth=c("
                  + peakWidth.getMin()
                  * SECONDS_PER_MINUTE
                  + ", "
View Full Code Here

    finishedPercentage = 0.3f;

    synchronized (RUtilities.R_SEMAPHORE) {

      // Load gplots library
      if (rEngine.eval("require(gplots)").asBool().isFALSE()) {
        setStatus(TaskStatus.ERROR);
        errorMessage = "Heap maps plot requires the \"gplots\" R package, which could not be loaded. Please add it to your R installation.";
      }

      try {
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.