Investment Studio > Expressions > Functions > Statistical > NEGBINOMDIST
float negbinomdist(integer failures, integer successes, float success_probability)
Returns the negative binomial ("Pascal") distribution, i.e. the probability of experiencing the specified number of failures before reaching the specified number of successes in a series of Bernoulli trials (independent trials, where each trial can only result in success or failure).
failures is the number of failed outcomes.
successes is the number of successful outcomes.
The sum failures + successes = trials must be > 0.
success_probability Î [0, 1] is the probability of success in a single trial.
The negative binomial distribution is computed as
f(failures, successes, success_probability) = combin(failures + successes - 1, successes - 1) * success_probability^successes * (1 - success_probability)^failures
Example
The probability of having to flip an evenly balanced coin 10 times to get 3 heads (and hence 7 tails) is
=negbinomdist(7, 3, 0.5)
» 3.5%. The probability of having to flip the coin 20 times is
=negbinomdist(17, 3, 0.5)
» 0.016%.
See also binomdist, combin, critbinom, fact, hypgeomdist, permut, prob.