Class StatisticsConfiguration
java.lang.Object
org.apache.commons.statistics.descriptive.StatisticsConfiguration
Configuration for computation of statistics.
This class is immutable.
- Since:
- 1.1
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final booleanFlag to control if the statistic is biased, or should use a bias correction.private static final StatisticsConfigurationDefault instance. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateStatisticsConfiguration(boolean biased) Create an instance. -
Method Summary
Modifier and TypeMethodDescriptionbooleanisBiased()Checks if the calculation of the statistic is biased.withBiased(boolean v) Return an instance with the configured biased option.static StatisticsConfigurationReturn an instance using the default options.
-
Field Details
-
DEFAULT
Default instance. -
biased
private final boolean biasedFlag to control if the statistic is biased, or should use a bias correction.
-
-
Constructor Details
-
StatisticsConfiguration
private StatisticsConfiguration(boolean biased) Create an instance.- Parameters:
biased- Biased option.
-
-
Method Details
-
withDefaults
Return an instance using the default options.- Returns:
- default instance
-
withBiased
Return an instance with the configured biased option.The correction of bias in a statistic is implementation dependent. If set to
truethen bias correction will be disabled.This option is used by:
- Parameters:
v- Value.- Returns:
- an instance
-
isBiased
public boolean isBiased()Checks if the calculation of the statistic is biased. Iffalsethe calculation should use a bias correction.- Returns:
- true if biased
-