IGLib  1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Meta.Numerics.Statistics.Distributions.BernoulliDistribution Class Reference

Represents a Bernoulli distribution. More...

+ Inheritance diagram for Meta.Numerics.Statistics.Distributions.BernoulliDistribution:
+ Collaboration diagram for Meta.Numerics.Statistics.Distributions.BernoulliDistribution:

Public Member Functions

 BernoulliDistribution (double p1)
 Initializes a new Bernoulli distribution. More...
 
override double ProbabilityMass (int k)
 Returns the probability of the obtaining the given value.
Parameters
kThe value.
Returns
The probability of obtaining the value.
More...
 
override double Moment (int r)
 Computes a raw moment of the distribution.
Parameters
rThe order of the moment to compute.
Returns
The rth raw moment of the distribution.
See also
Moment
More...
 
override double MomentAboutMean (int r)
 Computes a central moment of the distribution.
Parameters
rThe order of the moment to compute.
Returns
The rth central moment of the distribution.
See also
Moment
More...
 
override double LeftExclusiveProbability (int k)
 Computes the probability of obtaining a value less than the given value.
Parameters
kThe value.
Returns
The total probability of obtaining a value strictly less than k .
See also
RightExclusiveProbability
More...
 
override double RightExclusiveProbability (int k)
 Computes the probability of obtaining a value greater than the given value.
Parameters
kThe value.
Returns
The total probability of obtaining a value strictly greater than k .
See also
LeftExclusiveProbability
More...
 
override int InverseLeftProbability (double P)
 Computes the value corresponding to the given percentile.
Parameters
PThe percentile.
Returns
The value.
More...
 
- Public Member Functions inherited from Meta.Numerics.Statistics.Distributions.DiscreteDistribution
virtual double LeftInclusiveProbability (int k)
 Computes the probability of obtaining a value less than or equal to the given value. More...
 
virtual double ExpectationValue (Func< int, double > f)
 Computes the expectation value of an artibrary function. More...
 
override double Moment (int r)
 Gets a raw moment of the distribution. More...
 
override double MomentAboutMean (int r)
 Gets a central moment of the distribution. More...
 
virtual int GetRandomValue (Random rng)
 Produces a random integer drawn from the distribution. More...
 
- Public Member Functions inherited from Meta.Numerics.Statistics.Distributions.UnivariateDistribution
virtual double Cumulant (int r)
 Computes a cumulant of the distribution. More...
 

Properties

override int Minimum [get]
 
override int Maximum [get]
 
override double Mean [get]
 
override double Variance [get]
 
override double Skewness [get]
 
override double ExcessKurtosis [get]
 
- Properties inherited from Meta.Numerics.Statistics.Distributions.DiscreteDistribution
abstract int Minimum [get]
 Gets the smallest value in the distribution. More...
 
abstract int Maximum [get]
 Gets the largest value in the distribution. More...
 
override double Mean [get]
 Gets the mean of the distribution. More...
 
- Properties inherited from Meta.Numerics.Statistics.Distributions.UnivariateDistribution
virtual double Mean [get]
 Gets the mean of the distribution. More...
 
virtual double Variance [get]
 Gets the variance of the distribution. More...
 
virtual double StandardDeviation [get]
 Gets the standard deviation of the distribution. More...
 
virtual double Skewness [get]
 Gets the skewness of the distribution. More...
 
virtual double ExcessKurtosis [get]
 Gets the excess kurtosis of the distribution. More...
 

Private Attributes

double p
 
double q
 

Detailed Description

Represents a Bernoulli distribution.

A Bernoulli distribution describes a trial with two possible outcomes. These outcomes are usually called "success" and "failure", but the same framework is applicable to any binary set of outcomes: right or left, true or false, male or female, dead or alive, etc. We represent the outcomes by 1 and 0, which are the only two integers for which the Bernoulli probability does not vanish. The parameter p1 is the probability of obtaining outcome 1.

When multiple, independent Bernoulli trials are conducted, the binomial distribution (BinomialDistribution) describes the probablity of obtaining any particular number of successes.

See also
BinomialDistribution

Constructor & Destructor Documentation

Meta.Numerics.Statistics.Distributions.BernoulliDistribution.BernoulliDistribution ( double  p1)
inline

Initializes a new Bernoulli distribution.

Parameters
p1The probability of outcome 1, which must lie between zero and one.

Member Function Documentation

override double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.ProbabilityMass ( int  k)
inlinevirtual

Returns the probability of the obtaining the given value.

Parameters
kThe value.
Returns
The probability of obtaining the value.

Implements Meta.Numerics.Statistics.Distributions.DiscreteDistribution.

override double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.Moment ( int  r)
inlinevirtual

Computes a raw moment of the distribution.

Parameters
rThe order of the moment to compute.
Returns
The rth raw moment of the distribution.
See also
Moment

Implements Meta.Numerics.Statistics.Distributions.UnivariateDistribution.

override double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.MomentAboutMean ( int  r)
inlinevirtual

Computes a central moment of the distribution.

Parameters
rThe order of the moment to compute.
Returns
The rth central moment of the distribution.
See also
Moment

Reimplemented from Meta.Numerics.Statistics.Distributions.UnivariateDistribution.

References Meta.Numerics.MoreMath.Pow().

override double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.LeftExclusiveProbability ( int  k)
inlinevirtual

Computes the probability of obtaining a value less than the given value.

Parameters
kThe value.
Returns
The total probability of obtaining a value strictly less than k .
See also
RightExclusiveProbability

Reimplemented from Meta.Numerics.Statistics.Distributions.DiscreteDistribution.

override double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.RightExclusiveProbability ( int  k)
inlinevirtual

Computes the probability of obtaining a value greater than the given value.

Parameters
kThe value.
Returns
The total probability of obtaining a value strictly greater than k .
See also
LeftExclusiveProbability

Reimplemented from Meta.Numerics.Statistics.Distributions.DiscreteDistribution.

override int Meta.Numerics.Statistics.Distributions.BernoulliDistribution.InverseLeftProbability ( double  P)
inlinevirtual

Computes the value corresponding to the given percentile.

Parameters
PThe percentile.
Returns
The value.

Reimplemented from Meta.Numerics.Statistics.Distributions.DiscreteDistribution.

Member Data Documentation

double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.p
private
double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.q
private

Property Documentation

override int Meta.Numerics.Statistics.Distributions.BernoulliDistribution.Minimum
get

override int Meta.Numerics.Statistics.Distributions.BernoulliDistribution.Maximum
get

override double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.Mean
get

override double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.Variance
get

override double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.Skewness
get

override double Meta.Numerics.Statistics.Distributions.BernoulliDistribution.ExcessKurtosis
get


The documentation for this class was generated from the following file: