Saturday, 26 October 2013

Pascal Distribution CDF and Quantile Calculator

An implementation of the Pascal Distribution CDF and Quantile function Calculator occurs below. The Pascal Distribution is also known as the Negative Binomial Distribution and is a Probability Mass Function as it describes the distribution of discrete random variables, which are integers from 0 upwards i.e. positive integers. For parameters $r$ (integer, greater than or equal to 0) and $p$ (which must lie between 0 and 1) the Negative Binomial distribution function is:-


$\Large {k+r-1 \choose k}p^r(1-p)^k$  


We can regard $k$ as the number of successes and $p$ as the probability of failure of each trial, while $r$ is the number of failures. The $r$ and $p$ fields have to be filled in, as well as one out of the two fields which are labelled Upper Limit and Probability (the Lower limit is fixed to 0). The upper limit field needs to contain an integer number greater than or equal to 0. The probability field must contain a number between 0 and 1 only.



$r$:
$p$:


Upper limit:
Probablility:



Plot of distribution ($f(x)$) values against $x$ values
$f(x)$
$x$


No comments:

Post a Comment

Logistic Regression Calculator and ROC Curve Plotter

This blog post implements a Logistic Regression calculator for a binary output. Consider a binary outcome response variable \(Y\...