
SSJ V. 2.6. 

PREV PACKAGE NEXT PACKAGE  FRAMES NO FRAMES 
See:
Description
Interface Summary  

Distribution  This interface should be implemented by all classes supporting discrete and continuous distributions. 
Class Summary  

AndersonDarlingDist  Extends the class ContinuousDistribution for the
AndersonDarling distribution (see). 
AndersonDarlingDistQuick  Extends the class AndersonDarlingDist for the
distribution (see). 
BernoulliDist  Extends the class DiscreteDistributionInt for the Bernoulli
distribution with parameter p, where
0 <= p <= 1. 
BetaDist  Extends the class ContinuousDistribution for
the beta distribution with shape parameters
α > 0 and β > 0, over the interval [a, b], where a < b. 
BetaSymmetricalDist  Specializes the class BetaDist to the case of a symmetrical
beta distribution over the interval [0, 1],
with shape parameters
α = β. 
BinomialDist  Extends the class DiscreteDistributionInt for the
binomial distribution with parameters n and p, where
n is a positive integer and
0 <= p <= 1. 
CauchyDist  Extends the class ContinuousDistribution for
the Cauchy distribution
with location parameter α
and scale parameter β > 0. 
ChiDist  Extends the class ContinuousDistribution for the chi
distribution with shape parameter
v > 0, where the number of degrees of freedom
v is a positive integer. 
ChiSquareDist  Extends the class ContinuousDistribution for
the chisquare distribution with n degrees of freedom,
where n is a positive integer. 
ChiSquareDistQuick  Provides a variant of ChiSquareDist with
faster but less accurate methods. 
ChiSquareNoncentralDist  Extends the class ContinuousDistribution for
the noncentral chisquare distribution with ν degrees of freedom
and noncentrality parameter λ, where ν > 0 and
λ > 0. 
ConstantDist  Represents a constant discrete distribution taking a single real value with probability 1. 
ConstantIntDist  Represents a constant discrete distribution taking a single integer value with probability 1. 
ContinuousDistribution  Classes implementing continuous distributions should inherit from this base class. 
CramerVonMisesDist  Extends the class ContinuousDistribution for the
Cramérvon Mises distribution (see). 
DiscreteDistribution  This class implements discrete distributions over a finite set of real numbers (also over integers as a particular case). 
DiscreteDistributionInt  Classes implementing discrete distributions over the integers should inherit from this class. 
DistributionFactory  This class implements a string API for the package probdist. 
EmpiricalDist  Extends DiscreteDistribution to an empirical
distribution function,
based on the observations
X_{(1)},..., X_{(n)} (sorted by increasing order). 
ErlangDist  Extends the class GammaDist for the special case
of the Erlang distribution with
shape parameter k > 0 and scale parameter
λ > 0. 
ExponentialDist  Extends the class ContinuousDistribution for
the exponential distribution
with mean 1/λ where
λ > 0. 
ExponentialDistFromMean  Extends the ExponentialDist class with a constructor accepting as
argument the mean 1/λ instead of the rate λ. 
ExtremeValueDist  Deprecated. 
FatigueLifeDist  Extends the class ContinuousDistribution for
the fatigue life distribution with location
parameter μ, scale parameter β and shape
parameter γ. 
FisherFDist  Extends the class ContinuousDistribution for
the Fisher F distribution with n_{1} and n_{2}
degrees of freedom, where n_{1} and n_{2} are positive integers. 
FoldedNormalDist  Extends the class ContinuousDistribution for
the folded normal distribution with
parameters μ >= 0 and
σ > 0. 
FrechetDist  Extends the class ContinuousDistribution for the Fréchet
distribution, with location parameter δ, scale
parameter β > 0, and shape parameter
α > 0, where we use
the notation
z = (x  δ)/β. 
GammaDist  Extends the class ContinuousDistribution for
the gamma distribution with
shape parameter
α > 0 and scale parameter
λ > 0. 
GammaDistFromMoments  Extends the GammaDist distribution with constructors accepting the
mean μ and variance σ^{2} as arguments instead of a shape parameter
α and a scale parameter λ. 
GeometricDist  Extends the class DiscreteDistributionInt for
the geometric distribution with parameter
p, where 0 < p < 1. 
GumbelDist  Extends the class ContinuousDistribution for
the Gumbel distribution, with location parameter
δ and scale parameter
β≠ 0. 
HalfNormalDist  Extends the class ContinuousDistribution for the halfnormal
distribution with parameters μ and
σ > 0. 
HyperbolicSecantDist  Extends the class ContinuousDistribution for
the hyperbolic secant distribution with location
parameter μ and scale parameter
σ > 0. 
HypergeometricDist  Extends the class DiscreteDistributionInt for
the hypergeometric distribution with
k elements chosen among l, m being
of one type, and l  m of the other. 
HypoExponentialDist  This class implements the hypoexponential distribution, also called the generalized Erlang distribution. 
HypoExponentialDistEqual  This class implements the hypoexponential distribution for the case of equidistant λ_{i} = (n + 1  i)h. 
HypoExponentialDistQuick  This class is a subclass of HypoExponentialDist
and also implements the hypoexponential distribution. 
InverseDistFromDensity  Implements a method for computing the inverse of an arbitrary continuous distribution function when only the probability density is known. 
InverseGammaDist  Extends the class ContinuousDistribution for
the inverse gamma distribution with shape parameter
α > 0 and scale parameter β > 0. 
InverseGaussianDist  Extends the class ContinuousDistribution for
the inverse Gaussian distribution with location parameter
μ > 0 and scale parameter
λ > 0. 
JohnsonSBDist  Extends the class ContinuousDistribution for
the Johnson S_{B} distribution
with shape parameters γ and
δ > 0, location parameter ξ,
and scale parameter λ > 0. 
JohnsonSLDist  Extends the class ContinuousDistribution for
the Johnson S_{L} distribution. 
JohnsonSUDist  Extends the class ContinuousDistribution for
the Johnson S_{U} distribution. 
KolmogorovSmirnovDist  Extends the class ContinuousDistribution for the
KolmogorovSmirnov distribution with parameter n. 
KolmogorovSmirnovDistQuick  Extends the class KolmogorovSmirnovDist for the distribution. 
KolmogorovSmirnovPlusDist  Extends the class ContinuousDistribution for the
KolmogorovSmirnov+ distribution (see). 
LaplaceDist  Extends the class ContinuousDistribution for
the Laplace distribution. 
LogarithmicDist  Extends the class DiscreteDistributionInt for
the logarithmic distribution. 
LogisticDist  Extends the class ContinuousDistribution for the
logistic distribution. 
LoglogisticDist  Extends the class ContinuousDistribution for the
LogLogistic distribution with shape parameter
α > 0
and scale parameter β > 0. 
LognormalDist  Extends the class ContinuousDistribution for the
lognormal distribution. 
LognormalDistFromMoments  Extends the LognormalDist class with a constructor accepting the
mean m and the variance v of the distribution as arguments. 
NakagamiDist  Extends the class ContinuousDistribution for
the Nakagami distribution with location parameter a,
scale parameter
λ > 0 and shape parameter c > 0. 
NegativeBinomialDist  Extends the class DiscreteDistributionInt for
the negative binomial distribution with real
parameters n and p, where n > 0 and
0 <= p <= 1. 
NormalDist  Extends the class ContinuousDistribution for the normal
distribution (e.g.,). 
NormalDistQuick  A variant of the class NormalDist (for the normal
distribution with mean μ and variance σ^{2}). 
NormalInverseGaussianDist  Extends the class ContinuousDistribution for
the normal inverse gaussian distribution with location parameter
μ, scale parameter
δ > 0, tail heavyness
α > 0, and
asymmetry parameter β such that
0 <=  β < α. 
ParetoDist  Extends the class ContinuousDistribution for a distribution
from the Pareto family, with
shape parameter
α > 0 and location parameter β > 0. 
PascalDist  The Pascal distribution is a special case of the negative binomial distribution with parameters n and p, where n is a positive integer and 0 <= p <= 1. 
Pearson5Dist  Deprecated. 
Pearson6Dist  Extends the class ContinuousDistribution for
the Pearson type VI distribution with shape parameters
α_{1} > 0 and
α_{2} > 0, and scale parameter β > 0. 
PiecewiseLinearEmpiricalDist  Extends the class ContinuousDistribution for a piecewiselinear
approximation of the empirical distribution function,
based on the observations
X_{(1)},..., X_{(n)} (sorted by increasing order),
and defined as follows (e.g.,). 
PoissonDist  Extends the class DiscreteDistributionInt for the
Poisson distribution with mean
λ >= 0. 
PowerDist  Extends the class ContinuousDistribution for
the power distribution with shape parameter
c > 0, over the interval [a, b], where a < b. 
RayleighDist  This class extends the class ContinuousDistribution for
the Rayleigh distribution with
location parameter a, and scale parameter β > 0. 
StudentDist  Extends the class ContinuousDistribution for
the Student tdistribution
with n degrees of freedom, where n is a positive integer. 
StudentDistQuick  Extends the class StudentDist for
the Student tdistribution. 
TriangularDist  Extends the class ContinuousDistribution for
the triangular distribution with domain [a, b] and mode
(or shape parameter) m, where
a <= m <= b. 
TruncatedDist  This container class takes an arbitrary continuous distribution and truncates it to an interval [a, b], where a and b can be finite or infinite. 
UniformDist  Extends the class ContinuousDistribution for
the uniform distribution
over the interval [a, b]. 
UniformIntDist  Extends the class DiscreteDistributionInt for
the discrete uniform distribution over the range [i, j]. 
WatsonGDist  Extends the class ContinuousDistribution for the
Watson G distribution (see). 
WatsonUDist  Extends the class ContinuousDistribution for the
Watson U distribution (see). 
WeibullDist  This class extends the class ContinuousDistribution for
the Weibull distribution with shape parameter
α > 0, location parameter δ, and scale parameter
λ > 0. 
This package contains a set of Java classes providing methods to
compute mass, density, distribution, complementary
distribution, and inverse distribution functions for some discrete
and continuous probability distributions.
It also provides methods to estimate the parameters of some distributions
from empirical data.
It does not generate random variates;
for that, see the package randvar
.
It is possible to plot the density or the cumulative probabilities of a
distribution function either on screen, or in a L^{A}TEX file, but for this,
one has to use the package
charts
.
We recall that the distribution function of a continuous random variable X with density f over the real line is
while that of a discrete random variable X with mass function p over a fixed set of real numbers x_{0} < x_{1} < x_{2} < ^{ ... } is where p(x_{i}) = P[X = x_{i}]. For a discrete distribution over the set of integers, one has where p(s) = P[X = s].We define bar(F), the complementary distribution function of X, by
The inverse distribution function is defined as
for 0 <= u <= 1. This function F^{1} is often used, among other things, to generate the random variable X by inversion, by passing a U(0, 1) random variate as the value of u.The package probdist offers two types of tools for computing p, f, F, bar(F), and F^{1}: static methods, for which no object needs to be created, and methods associated with distribution objects. Standard distributions are implemented each in their own class. Constructing an object from one of these classes can be convenient if F, bar(F), etc., has to be evaluated several times for the same distribution. In certain cases (for the Poisson distribution, for example), creating the distribution object would precompute tables that would speed up significantly all subsequent method calls for computing F, bar(F), etc. This trades memory, plus a onetime setup cost, for speed. In addition to the nonstatic methods, the distribution classes also provide static methods that do not require the creation of an object.
The distribution classes extend one of the (abstract) classes
DiscreteDistribution
and
ContinuousDistribution
(which both implement the interface
Distribution
)
for discrete and continuous distributions over the real numbers,
or DiscreteDistributionInt
,
for discrete distributions over the nonnegative integers.
For example, the class
PoissonDist
extends
DiscreteDistributionInt
.
Calling a static method from this class
will compute the corresponding probability from scratch.
Constructing a PoissonDist
object, on the other hand,
will precompute tables that contain the probability terms and the
distribution function for a given parameter λ (the mean of the
Poisson distribution). These tables will then be used whenever
a method is called for the corresponding object.
This second approach is recommended if some of F, bar(F), etc.,
has to be computed several times for the same parameter λ.
As a rule of thumb, creating objects and using their methods
is faster than just using static methods as soon as two or three
calls are made, unless the parameters are large.
In fact, only the nonnegligible probability terms
(those that exceed the threshold
DiscreteDistributionInt.EPSILON
)
are stored in the tables. For F and bar(F), a single table actually
contains F(x) for
F(x) <= 1/2 and 1  F(x) for
F(x) > 1/2.
When the distribution parameters are so large that the tables would
take too much space, these are not created and the methods
automatically call their static equivalents instead of using tables.
Objects that implement the interface
Distribution
(and sometimes the abstract class
ContinuousDistribution
)
are required by some methods in
package randvar
and also in classes
GofStat
and
GofFormat
of
package gof
.
Some of the classes also provide methods that compute parameter estimations of the corresponding distribution from a set of empirical observations, in most cases based on the maximum likelihood method.

SSJ V. 2.6. 

PREV PACKAGE NEXT PACKAGE  FRAMES NO FRAMES 