binomialp

double binomialp(int x, int n, double p);

Returns the value of the Binomial random variable distribution function with n trials and p chance of success at the value x.

Parameters:
xCritical point.
nNumber of trials.
pProbability of success.

Returns:
P(X ≤ x | n, p)

Errors:
NUMERICS_ERROR is raised if p ≤ 0, p ≥ 1, or n ≤ 1

Usage:
double p = binomialp(5, 10, 0.75)

Header:
#include "discdist.h"