ij.measure.ResultsTable.setLabel()方法的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(5.0k)|赞(0)|评价(0)|浏览(57)

本文整理了Java中ij.measure.ResultsTable.setLabel方法的一些代码示例,展示了ResultsTable.setLabel的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ResultsTable.setLabel方法的具体详情如下:
包路径:ij.measure.ResultsTable
类名称:ResultsTable
方法名:setLabel

ResultsTable.setLabel介绍

[英]Adds a label to the beginning of the specified row, or updates an existing lable, where 0show() to update the window displaying the table.
[中]将标签添加到指定行的开头,或更新现有标签,其中0show()用于更新显示表格的窗口。

代码示例

代码示例来源:origin: net.imagej/imagej-legacy

@Override
public void setRowHeader(final int row, final String header) {
  table.setLabel(header, row);
}

代码示例来源:origin: net.imagej/imagej-legacy

@Override
public void setLabel(final String label, final int row) {
  super.setLabel(label, row);
  source.setRowHeader(row, label);
}

代码示例来源:origin: net.imagej/imagej-legacy

@Override
public void appendRow(final String header) {
  appendRow(); // incremented row count
  table.setLabel(header, table.size() - 1);
}

代码示例来源:origin: net.imagej/ij

rt.incrementCounter(); rt.setLabel("Mean", n+0);
rt.incrementCounter(); rt.setLabel("SD", n+1);
rt.incrementCounter(); rt.setLabel("Min", n+2);
rt.incrementCounter(); rt.setLabel("Max", n+3);
for (int col=first; col<columns; col++) {
  rt.setValue(headings[col], n+0, sum[col]/n);

代码示例来源:origin: imagej/ImageJA

rt.incrementCounter(); rt.setLabel("Mean", n+0);
rt.incrementCounter(); rt.setLabel("SD", n+1);
rt.incrementCounter(); rt.setLabel("Min", n+2);
rt.incrementCounter(); rt.setLabel("Max", n+3);
for (int col=first; col<columns; col++) {
  rt.setValue(headings[col], n+0, sum[col]/n);

代码示例来源:origin: fiji/TrackMate

lTable.setLabel( "TRACK_ID", 0 );
for ( int i = 0; i < ncols; i++ )
  lTable.setLabel( feature, j + 1 );
  for ( int i = 0; i < ncols; i++ )

代码示例来源:origin: sc.fiji/TrackMate_

lTable.setLabel( "TRACK_ID", 0 );
for ( int i = 0; i < ncols; i++ )
  lTable.setLabel( feature, j + 1 );
  for ( int i = 0; i < ncols; i++ )

代码示例来源:origin: imagej/ImageJA

void doBoxCounts(ImageProcessor ip) {
    if (!FindMargins(ip))
      return;
    ResultsTable rt=ResultsTable.getResultsTable();
    rt.incrementCounter();
    rt.setLabel(imp.getShortTitle(), rt.size()-1);
    for (int i=0; i<boxSizes.length; i++) {
      int boxSum = count(boxSizes[i], ip);
      rt.addValue("C"+boxSizes[i], boxSum);
      boxCountSums[i] = (float)Math.log(boxSum);
    }
    double D = plot();
    rt.addValue("D", D);
    rt.show("Results");
    imp.deleteRoi();
  }
}

代码示例来源:origin: net.imagej/ij

void doBoxCounts(ImageProcessor ip) {
    if (!FindMargins(ip))
      return;
    ResultsTable rt=ResultsTable.getResultsTable();
    rt.incrementCounter();
    rt.setLabel(imp.getShortTitle(), rt.size()-1);
    for (int i=0; i<boxSizes.length; i++) {
      int boxSum = count(boxSizes[i], ip);
      rt.addValue("C"+boxSizes[i], boxSum);
      boxCountSums[i] = (float)Math.log(boxSum);
    }
    double D = plot();
    rt.addValue("D", D);
    rt.show("Results");
    imp.deleteRoi();
  }
}

代码示例来源:origin: net.imagej/ij

/** Sorts this table on the specified column. TO DO: add string support.*/
public void sort(String column) {
  int col = getColumnIndex(column);
  if (col==COLUMN_NOT_FOUND)
    throw new IllegalArgumentException("Column not found");
  double[] values = new double[size()];
  for (int i=0; i<size(); i++)
    values[i] = getValueAsDouble(col,i);
  int[] indexes = Tools.rank(values);
  ResultsTable rt2 = (ResultsTable)clone();
  String[] headers = getHeadings();
  for (int i=0; i<headers.length; i++) {
    if ("Label".equals(headers[i])) {
      for (int row = 0; row<size(); row++)
        setLabel(rt2.getLabel(indexes[row]), row);
    } else {
      col = getColumnIndex(headers[i]);
      for (int row = 0; row<size(); row++)
        setValue(col, row, rt2.getValueAsDouble(col,indexes[row]));
    }
  }
}

代码示例来源:origin: imagej/ImageJA

/** Sorts this table on the specified column. TO DO: add string support.*/
public void sort(String column) {
  int col = getColumnIndex(column);
  if (col==COLUMN_NOT_FOUND)
    throw new IllegalArgumentException("Column not found");
  double[] values = new double[size()];
  for (int i=0; i<size(); i++)
    values[i] = getValueAsDouble(col,i);
  int[] indexes = Tools.rank(values);
  ResultsTable rt2 = (ResultsTable)clone();
  String[] headers = getHeadings();
  for (int i=0; i<headers.length; i++) {
    if ("Label".equals(headers[i])) {
      for (int row = 0; row<size(); row++)
        setLabel(rt2.getLabel(indexes[row]), row);
    } else {
      col = getColumnIndex(headers[i]);
      for (int row = 0; row<size(); row++)
        setValue(col, row, rt2.getValueAsDouble(col,indexes[row]));
    }
  }
}

代码示例来源:origin: net.imagej/ij

s += colon+currentSlice;
rt.setLabel(s, rt.size()-1);

代码示例来源:origin: zitmen/thunderstorm

s += colon+currentSlice;
rt.setLabel(s, rt.getCounter()-1);

代码示例来源:origin: imagej/ImageJA

s += colon+currentSlice;
rt.setLabel(s, rt.size()-1);

代码示例来源:origin: net.imagej/ij

if (stringValue!=null) {
  if (isLabel)
    rt.setLabel(stringValue, row);
  else
    rt.setValue(column, row, stringValue);

代码示例来源:origin: imagej/ImageJA

if (stringValue!=null) {
  if (isLabel)
    rt.setLabel(stringValue, row);
  else
    rt.setValue(column, row, stringValue);

代码示例来源:origin: ijpb/MorphoLibJ

rt_final.incrementCounter();
rt1.setLabel("Row #"+(i+1), i);
rt2.setLabel("Row #"+(i+1), i);
rt3.setLabel("Row #"+(i+1), i);
rt_final.setLabel("Row #"+(i+1), i);

代码示例来源:origin: net.imagej/imagej-legacy

ij1Table.setLabel(table.getRowHeader(r), r);
for (int c = 0; c < table.getColumnCount(); c++) {
  String header = table.getColumnHeader(c);

相关文章

微信公众号

最新文章

更多