The Beta distribution with shape parameters \(a\) (argument shape1
) and \(b\) (argument shape2
) and denoted as \(Beta(a,b)\), where \(a>0\) and \(b>0\), has a probability density function given by (Kleiber and Kotz, 2003; Johnson et al., 1995; Yee, 2022)
$$f(y) = \displaystyle \frac{1}{B(a,b)}y^{a-1}(1-y)^{b-1},$$
and a cumulative distribution function given by
$$F(y)= \displaystyle \frac{B(y;a,b)}{B(a,b)} $$
where \(0 \leq y \leq 1\),
$$B(a,b) = \displaystyle \frac{\Gamma(a)\Gamma(b)}{\Gamma(a+b)}$$
is the beta function,
$$\Gamma(\alpha) = \int_{0}^{\infty}t^{\alpha-1}e^{-t}dt$$ is the gamma function, and
$$B(y;a,b) = \displaystyle \int_{0}^{y}t^{a-1}(1-t)^{b-1}dt$$ is the incomplete beta function.
The Gini index can be computed as
$$G = \displaystyle \frac{2}{a}\frac{B(a+b,a+b)}{B(a,a)B(b,b)}.$$