Package net.sf.mzmine.data

Examples of net.sf.mzmine.data.PeakListRow


    PeakDataSet peakDataSet = (PeakDataSet) dataset;
    PeakDataPoint dataPoint = peakDataSet.getDataPoint(series, item);

    PeakList peakList = peakDataSet.getPeakList();
    ChromatographicPeak peak = peakDataSet.getPeak(series);
    PeakListRow row = peakList.getPeakRow(peak);
    double rtValue = dataPoint.getRT();
    double intValue = dataPoint.getIntensity();
    double mzValue = dataPoint.getMZ();
    int scanNumber = dataPoint.getScanNumber();
View Full Code Here


    setStatus(TaskStatus.PROCESSING);

    logger.info("Starting fragments search in " + peakList);

    PeakListRow rows[] = peakList.getRows();
    totalRows = rows.length;

    // Start with the highest peaks
    Arrays.sort(rows, new PeakListRowSorter(SortingProperty.Height,
        SortingDirection.Descending));
View Full Code Here

    }

    if (value instanceof PeakListRow) {

      PeakListRow plRow = (PeakListRow) value;

      RawDataFile[] dataFiles = peakList.getRawDataFiles();
      ChromatographicPeak[] peaks = new ChromatographicPeak[dataFiles.length];
      for (int i = 0; i < dataFiles.length; i++) {
        peaks[i] = plRow.getPeak(dataFiles[i]);
      }

      CombinedXICComponent xic = new CombinedXICComponent(peaks,
          plRow.getID());

      newPanel.add(xic);

      newPanel.setToolTipText(xic.getToolTipText());
View Full Code Here

   * if it is a missing value
   */

  public Object getValueAt(int row, int col) {

    PeakListRow peakListRow = peakList.getRow(row);

    if (isCommonColumn(col)) {
      CommonColumnType commonColumn = getCommonColumn(col);

      switch (commonColumn) {
        case ROWID :
          return new Integer(peakListRow.getID());
        case AVERAGEMZ :
          return new Double(peakListRow.getAverageMZ());
        case AVERAGERT :
          return new Double(peakListRow.getAverageRT());
        case COMMENT :
          return peakListRow.getComment();
        case IDENTITY :
          return peakListRow.getPreferredPeakIdentity();
        case PEAKSHAPE :
          return peakListRow;
      }

    } else {

      DataFileColumnType dataFileColumn = getDataFileColumn(col);
      RawDataFile file = getColumnDataFile(col);
      ChromatographicPeak peak = peakListRow.getPeak(file);

      if (peak == null) {
        if (dataFileColumn == DataFileColumnType.STATUS)
          return PeakStatus.UNKNOWN;
        else
View Full Code Here

  public void setValueAt(Object value, int row, int col) {

    CommonColumnType columnType = getCommonColumn(col);

    PeakListRow peakListRow = peakList.getRow(row);

    if (columnType == CommonColumnType.COMMENT) {
      peakListRow.setComment((String) value);
    }

    if (columnType == CommonColumnType.IDENTITY) {
      if (value instanceof PeakIdentity)
        peakListRow.setPreferredPeakIdentity((PeakIdentity) value);
    }

  }
View Full Code Here

          bestScan.getScanNumber(), scan.getScanNumber(), new Range(
              bestScan.getRetentionTime()), new Range(
              scan.getPrecursorMZ()), new Range(
              maxPoint.getIntensity()));

      PeakListRow entry = new SimplePeakListRow(scan.getScanNumber());
      entry.addPeak(dataFile, c);

      newPeakList.addRow(entry);
      processedScans++;
    }
View Full Code Here

      PeakListDataSet peakListDataSet = (PeakListDataSet) dataset;

      ChromatographicPeak peak = peakListDataSet.getPeak(series, item);

      PeakList peakList = peakListDataSet.getPeakList();
      PeakListRow row = peakList.getPeakRow(peak);

      String tooltip = "Peak: " + peak + "\nStatus: "
          + peak.getPeakStatus() + "\nPeak list row: " + row
          + "\nData point m/z: " + mzFormat.format(mzValue)
          + "\nData point intensity: "
View Full Code Here

    if (object instanceof PeakList) {
      int childCount = getChildCount(peakListsNode);
      insertNodeInto(newNode, peakListsNode, childCount);
      final PeakList peakList = (PeakList) object;
      PeakListRow rows[] = peakList.getRows();
      for (int i = 0; i < rows.length; i++) {
        DefaultMutableTreeNode rowNode = new DefaultMutableTreeNode(
            rows[i]);
        treeObjects.put(rows[i], rowNode);
        insertNodeInto(rowNode, newNode, i);
View Full Code Here

      errorMessage = "Could not read file or the file is empty ";
      return;
    }
    // Fill new peak list with empty rows
    for (int row = 0; row < peaks.size(); row++) {
      PeakListRow newRow = new SimplePeakListRow(ID++);
      processedPeakList.addRow(newRow);
    }

    // Process all raw data files

    // Canceled?
    if (isCanceled()) {
      return;
    }

    List<Gap> gaps = new ArrayList<Gap>();

    // Fill each row of this raw data file column, create new empty
    // gaps
    // if necessary
    for (int row = 0; row < peaks.size(); row++) {
      PeakListRow newRow = processedPeakList.getRow(row);
      // Create a new gap

      Range mzRange = mzTolerance.getToleranceRange(peaks.get(row)
          .getMZ());
      Range rtRange = rtTolerance.getToleranceRange(peaks.get(row)
          .getRT());
      newRow.addPeakIdentity(new SimplePeakIdentity(peaks.get(row)
          .getName()), true);

      Gap newGap = new Gap(newRow, dataFile, mzRange, rtRange,
          intTolerance);
View Full Code Here

   */
  public String generateLabel(XYDataset dataSet, int series, int item) {

    ScatterPlotDataSet scatterDataSet = (ScatterPlotDataSet) dataSet;

    PeakListRow row = scatterDataSet.getRow(series, item);
    PeakIdentity identity = row.getPreferredPeakIdentity();
    if (identity != null) {
      return identity.getName();
    } else {
      return row.toString();
    }

  }
View Full Code Here

TOP

Related Classes of net.sf.mzmine.data.PeakListRow

Copyright © 2018 www.massapicom. 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.