All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class maths.statistics.NormalDistribution

java.lang.Object
   |
   +----maths.statistics.ProbabilityDistribution
           |
           +----maths.statistics.NormalDistribution

public final class NormalDistribution
extends ProbabilityDistribution
The NormalDistribution class provides an object for encapsulating normal distributions.

Version:
1.1
Author:
Jaco van Kooten

Constructor Index

 o NormalDistribution()
Constructs a normal distribution with zero mean and unity variance.
 o NormalDistribution(double, double)
Constructs a normal distribution.
 o NormalDistribution(double[])
Constructs a normal distribution from a dataset.

Method Index

 o cumulative(double)
Cumulative normal distribution function.
 o getMean()
Returns the mean.
 o getVariance()
Returns the variance.
 o inverse(double)
Inverse of the cumulative normal distribution function.
 o probability(double)
Probability density function of a normal (Gaussian) distribution.

Constructors

 o NormalDistribution
 public NormalDistribution()
Constructs a normal distribution with zero mean and unity variance.

 o NormalDistribution
 public NormalDistribution(double mu,
                           double var)
Constructs a normal distribution.

Parameters:
mu - the mean
var - the variance
 o NormalDistribution
 public NormalDistribution(double array[])
Constructs a normal distribution from a dataset.

Parameters:
array - a sample

Methods

 o getMean
 public double getMean()
Returns the mean.

 o getVariance
 public double getVariance()
Returns the variance.

 o probability
 public double probability(double X)
Probability density function of a normal (Gaussian) distribution.

Returns:
the probability that a stochastic variable x has the value X, i.e. P(x=X)
Overrides:
probability in class ProbabilityDistribution
 o cumulative
 public double cumulative(double X)
Cumulative normal distribution function.

Returns:
the probability that a stochastic variable x is less then X, i.e. P(x<X)
Overrides:
cumulative in class ProbabilityDistribution
 o inverse
 public double inverse(double probability)
Inverse of the cumulative normal distribution function.

Returns:
the value X for which P(x<X)
Overrides:
inverse in class ProbabilityDistribution

All Packages  Class Hierarchy  This Package  Previous  Next  Index