Interface RegionAnalyzer<T>

Type Parameters:
T - the type of the data computed for each region. May be a class instance, or a single Numeric type.
All Known Implementing Classes:
AverageThickness, BoundingBox, BoundingBox3D, Centroid, Centroid3D, Convexity, EquivalentEllipse, EquivalentEllipsoid, GeodesicDiameter, GeodesicDiameter3D, InertiaEllipse, InertiaEllipsoid, IntrinsicVolumesAnalyzer2D, IntrinsicVolumesAnalyzer3D, LargestInscribedBall, LargestInscribedCircle, MaxFeretDiameter, MaxFeretDiameter3D, OrientedBoundingBox2D, RegionAnalyzer2D, RegionAnalyzer3D

public interface RegionAnalyzer<T>
Common interface for classes devoted to the extraction of information from each region of label or binary image.
Author:
dlegland
  • Method Summary

    Modifier and Type Method Description
    java.util.Map<java.lang.Integer,​T> analyzeRegions​(ij.ImagePlus labelPlus)
    Generic method to compute the result of an analysis on each region of a label or binary image.
    ij.measure.ResultsTable computeTable​(ij.ImagePlus labelPlus)
    Returns the result of the analysis in the form of a ResultsTable, to facilitate concatenation of results obtained from several instances of RegionAnalyzer.
    ij.measure.ResultsTable createTable​(java.util.Map<java.lang.Integer,​T> results)
    Utility method that converts the detailed results of the analyzeRegions(ImagePlus) method into an instance of ResultsTable to facilitate display by ImageJ.
  • Method Details

    • analyzeRegions

      java.util.Map<java.lang.Integer,​T> analyzeRegions​(ij.ImagePlus labelPlus)
      Generic method to compute the result of an analysis on each region of a label or binary image.
      Parameters:
      labelPlus - a label or binary image of region(s)
      Returns:
      the mapping between each region label within the image and the result of the analysis for the regions
    • computeTable

      ij.measure.ResultsTable computeTable​(ij.ImagePlus labelPlus)

      Returns the result of the analysis in the form of a ResultsTable, to facilitate concatenation of results obtained from several instances of RegionAnalyzer.

      This method can be quickly implemented by using the two other methods analyzeRegions(ImagePlus) and createTable(Map):

      
        public ResultsTable computeTable(ImagePlus labelPlus)
        {
            return createTable(analyzeRegions(labelPlus));
        }
       
       
      Parameters:
      labelPlus - a label or binary image of region(s)
      Returns:
      an instance of ResultsTable containing results presented in a tabular format.
    • createTable

      ij.measure.ResultsTable createTable​(java.util.Map<java.lang.Integer,​T> results)
      Utility method that converts the detailed results of the analyzeRegions(ImagePlus) method into an instance of ResultsTable to facilitate display by ImageJ.
      Parameters:
      results - the mapping between each region label and the result of the analysis
      Returns:
      an instance of ResultsTable containing results presented in a tabular format.