Class SummaryMeasurementTable

java.lang.Object
qupath.lib.gui.measure.ui.SummaryMeasurementTable

public class SummaryMeasurementTable extends Object
Control to show a table to view measurements and properties of PathObject.
Since:
v0.6.0
  • Constructor Details

    • SummaryMeasurementTable

      public SummaryMeasurementTable(ImageData<BufferedImage> imageData, Predicate<PathObject> primaryFilter)
      Create a new measurement table.
      Parameters:
      imageData - the image data that the table should relate to (i.e. source of the objects)
      primaryFilter - main filter used to extract objects (e.g. detections, annotations)
      See Also:
  • Method Details

    • getPane

      public Pane getPane()
    • getTableModelStrings

      public static <T> List<String> getTableModelStrings(PathTableData<T> model, String delim, Collection<String> excludeColumns)
      Get a list of Strings representing table data.

      Each entry in the list corresponds to a row.

      Type Parameters:
      T - the data type for the table
      Parameters:
      model -
      delim -
      excludeColumns -
      Returns:
    • getTableModelString

      public static <T> String getTableModelString(PathTableData<T> model, String delim, Collection<String> excludeColumns) throws IllegalArgumentException
      Get a single String representing the data in a table.

      Note: if the required String is too long (approximately Integer.MAX_VALUE characters), this will throw an IllegalArgumentException.

      Type Parameters:
      T - the data type for the items in the table
      Parameters:
      model -
      delim -
      excludeColumns -
      Returns:
      Throws:
      IllegalArgumentException
    • copyTableContentsToClipboard

      public static void copyTableContentsToClipboard(PathTableData<?> model, Collection<String> excludeColumns)
      Get a single String representing the data in a table and copy it to the clipboard.

      Note: this may not be possible if the String is too long, see getTableModelString(PathTableData, String, Collection).

      Parameters:
      model -
      excludeColumns -
    • saveTableModel

      public static boolean saveTableModel(PathTableData<?> tableModel, File fileOutput, Collection<String> excludeColumns)
      Save the data from a table to a text file, using the default delimiter from PathPrefs.
      Parameters:
      tableModel - the data to export
      fileOutput - the file to write the text to; if null, a file chooser will be shown
      excludeColumns - headings for columns that should be excluded
      Returns: