Package org.openjdk.jmh.util
Class AbstractStatistics
java.lang.Object
org.openjdk.jmh.util.AbstractStatistics
- All Implemented Interfaces:
Serializable,Comparable<Statistics>,org.apache.commons.math3.stat.descriptive.StatisticalSummary,Statistics
- Direct Known Subclasses:
ListStatistics,MultisetStatistics,SingletonStatistics
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintcompareTo(Statistics other) Compares this statistics to another one.intcompareTo(Statistics other, double confidence) Compares this statistics to another one.double[]getConfidenceIntervalAt(double confidence) Returns the interval c1, c2 of which there's an 1-alpha probability of the mean being within the interval.doublegetMean()Returns the arithmetic mean for this statistics.doublegetMeanErrorAt(double confidence) Gets the mean error at given confidence level.doubleReturns the standard deviation for this statistics.booleanisDifferent(Statistics other, double confidence) Checks if this statistics statistically different from the given one with the given confidence level.toString()Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.openjdk.jmh.util.Statistics
getHistogram, getMax, getMin, getN, getPercentile, getRawData, getSum, getVariance
-
Constructor Details
-
AbstractStatistics
public AbstractStatistics()
-
-
Method Details
-
getConfidenceIntervalAt
public double[] getConfidenceIntervalAt(double confidence) Returns the interval c1, c2 of which there's an 1-alpha probability of the mean being within the interval.- Specified by:
getConfidenceIntervalAtin interfaceStatistics- Parameters:
confidence- level- Returns:
- the confidence interval
-
isDifferent
Description copied from interface:StatisticsChecks if this statistics statistically different from the given one with the given confidence level.- Specified by:
isDifferentin interfaceStatistics- Parameters:
other- statistics to test againstconfidence- confidence level (e.g. 0.95)- Returns:
- true, if mean difference is statistically significant
-
getMeanErrorAt
public double getMeanErrorAt(double confidence) Description copied from interface:StatisticsGets the mean error at given confidence level.- Specified by:
getMeanErrorAtin interfaceStatistics- Parameters:
confidence- confidence level (e.g. 0.95)- Returns:
- the mean error with the given confidence level
-
toString
-
getMean
public double getMean()Description copied from interface:StatisticsReturns the arithmetic mean for this statistics.- Specified by:
getMeanin interfaceorg.apache.commons.math3.stat.descriptive.StatisticalSummary- Specified by:
getMeanin interfaceStatistics- Returns:
- arithmetic mean
-
getStandardDeviation
public double getStandardDeviation()Description copied from interface:StatisticsReturns the standard deviation for this statistics.- Specified by:
getStandardDeviationin interfaceorg.apache.commons.math3.stat.descriptive.StatisticalSummary- Specified by:
getStandardDeviationin interfaceStatistics- Returns:
- standard deviation
-
compareTo
Description copied from interface:StatisticsCompares this statistics to another one. Follows the contract ofComparable.- Specified by:
compareToin interfaceStatistics- Parameters:
other- statistics to compare againstconfidence- confidence level (e.g. 0.99)- Returns:
- a negative integer, zero, or a positive integer as this statistics is less than, equal to, or greater than the specified statistics.
-
compareTo
Description copied from interface:StatisticsCompares this statistics to another one. Follows the contract ofComparable.- Specified by:
compareToin interfaceComparable<Statistics>- Specified by:
compareToin interfaceStatistics- Parameters:
other- statistics to compare against- Returns:
- a negative integer, zero, or a positive integer as this statistics is less than, equal to, or greater than the specified statistics.
-