Class StatisticsToExport

Object
StatisticsToExport

public class StatisticsToExport extends Object
Statistics to be exported, comprised of name-value pairs.

The values may be of type int, double or String.

Typically, they are later written to a CSV file.

Author:
Owen Feehan
  • Constructor Details

    • StatisticsToExport

      public StatisticsToExport()
  • Method Details

    • append

      public void append(StatisticsToExport toAppend)
      Appends the names and values from another AnnotationComparison to the existing.

      Items are added to the end of their respective lists.

      This is a mutable operation.

      Parameters:
      toAppend - the comparison to append.
    • addString

      public void addString(String name, String value)
      Adds a statistic that is a String.
      Parameters:
      name - the name of the statistic.
      value - the value of the statistic.
    • addDouble

      public void addDouble(String name, double value)
      Adds a statistic that is a double.
      Parameters:
      name - the name of the statistic.
      value - the value of the statistic.
    • addInt

      public void addInt(String name, int value)
      Adds a statistic that is an int.
      Parameters:
      name - the name of the statistic.
      value - the value of the statistic.
    • addMeanExtrema

      public void addMeanExtrema(String name, double mean, double min, double max)
      Adds three statistics a mean, min and max.
      Parameters:
      name - the name of the statistic, which is capitalized and prefixed with mean, min and max respectively.
      mean - the mean.
      min - the min.
      max - the max.
    • addMeanExtrema

      public void addMeanExtrema(String name, RunningSumExtrema runningSum)
      Like addMeanExtrema(String, double, double, double) but determines the statistics from a RunningSumExtrema.
      Parameters:
      name - the name of the statistic, which is capitalized and prefixed with mean, min and max respectively.
      runningSum - the running-sum, also remembering extrema.
    • getNames

      public List<String> getNames()
      The names of statistics describing the annotation-comparison, as produced by getValues().
    • getValues

      public List<TypedValue> getValues()
      The values of statistics describing the annotation-comparison, corresponding exactly to the names in getNames().