Click or drag to resize
BernoulliDistribution Class
Represents a Bernoulli distribution.
Inheritance Hierarchy

Namespace:  Meta.Numerics.Statistics.Distributions
Assembly:  Meta.Numerics (in Meta.Numerics.dll) Version: (
public sealed class BernoulliDistribution : DiscreteDistribution

The BernoulliDistribution type exposes the following members.

Public methodBernoulliDistribution
Initializes a new Bernoulli distribution.
Public methodCumulant
Computes a cumulant of the distribution.
(Inherited from UnivariateDistribution.)
Public methodEquals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Public methodExpectationValue
Computes the expectation value of an artibrary function.
(Overrides DiscreteDistributionExpectationValue(FuncInt32, Double).)
Public methodGetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public methodGetRandomValue
Produces a random integer drawn from the distribution.
(Inherited from DiscreteDistribution.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodInverseLeftProbability
Computes the value corresponding to the given percentile.
(Overrides DiscreteDistributionInverseLeftProbability(Double).)
Public methodLeftExclusiveProbability
Computes the probability of obtaining a value less than the given value.
(Overrides DiscreteDistributionLeftExclusiveProbability(Int32).)
Public methodLeftInclusiveProbability
Computes the probability of obtaining a value less than or equal to the given value.
(Inherited from DiscreteDistribution.)
Public methodMoment
Gets a raw moment of the distribution.
(Overrides DiscreteDistributionMoment(Int32).)
Public methodMomentAboutMean
Gets a central moment of the distribution.
(Overrides DiscreteDistributionMomentAboutMean(Int32).)
Public methodProbabilityMass
Returns the probability of the obtaining the given value.
(Overrides DiscreteDistributionProbabilityMass(Int32).)
Public methodRightExclusiveProbability
Computes the probability of obtaining a value greater than the given value.
(Overrides DiscreteDistributionRightExclusiveProbability(Int32).)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)

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