public static class UniformIntegerDistribution.CDF extends UniformIntegerDistribution implements ClosedFormCumulativeDistributionFunction<java.lang.Number>
UniformIntegerDistribution.CDF, UniformIntegerDistribution.MaximumLikelihoodEstimator, UniformIntegerDistribution.PMF
DEFAULT_MAX_SUPPORT, DEFAULT_MIN_SUPPORT
Constructor and Description |
---|
CDF()
Creates a new
UniformIntegerDistribution.PMF with min and
max 0. |
CDF(int minSupport,
int maxSupport)
Creates a new
UniformIntegerDistribution.CDF with the given
min and max. |
CDF(UniformIntegerDistribution other)
Creates a new
UniformIntegerDistribution.CDF as a copy
of the given other uniform distribution. |
Modifier and Type | Method and Description |
---|---|
static double |
evaluate(int input,
int minSupport,
int maxSupport)
Evaluates the cumulative density function of the discrete uniform
distribution.
|
java.lang.Double |
evaluate(java.lang.Number input)
Evaluates the function on the given input and returns the output.
|
double |
evaluateAsDouble(int input)
Evaluates the cumulative distribution function for the input.
|
UniformIntegerDistribution.CDF |
getCDF()
Gets the CDF of a scalar distribution.
|
clone, convertFromVector, convertToVector, getDomain, getDomainSize, getEstimator, getMaxSupport, getMean, getMeanAsDouble, getMinSupport, getProbabilityFunction, getVariance, sampleAsInt, sampleInto, setMaxSupport, setMinSupport
sampleAsInts, sampleInto
sample, sample
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
clone, convertFromVector, convertToVector
getMaxSupport, getMeanAsDouble, getMinSupport, getVariance
getMean
sample, sample, sampleInto
public CDF()
UniformIntegerDistribution.PMF
with min and
max 0.public CDF(int minSupport, int maxSupport)
UniformIntegerDistribution.CDF
with the given
min and max.minSupport
- The minimum support. Should be less-than-or-equal to the max
support.maxSupport
- The maximum support. Should be greater-than-or-equal to the min
support.public CDF(UniformIntegerDistribution other)
UniformIntegerDistribution.CDF
as a copy
of the given other uniform distribution.other
- The other distribution.public java.lang.Double evaluate(java.lang.Number input)
Evaluator
public double evaluateAsDouble(int input)
input
- The input value.public static double evaluate(int input, int minSupport, int maxSupport)
input
- The input value.minSupport
- The minimum support. Should be less-than-or-equal to the max
support.maxSupport
- The maximum support. Should be greater-than-or-equal to the min
support.public UniformIntegerDistribution.CDF getCDF()
UnivariateDistribution
getCDF
in interface ClosedFormUnivariateDistribution<java.lang.Number>
getCDF
in interface UnivariateDistribution<java.lang.Number>
getCDF
in class UniformIntegerDistribution