Index: The Book of Statistical ProofsProbability DistributionsUnivariate continuous distributionsBeta distribution ▷ Variance

Theorem: Let $X$ be a random variable following a beta distribution:

\[\label{eq:beta} X \sim \mathrm{Bet}(\alpha, \beta) \; .\]

Then, the variance of $X$ is

\[\label{eq:beta-var} \mathrm{Var}(X) = \frac{\alpha \beta}{(\alpha + \beta + 1) \cdot (\alpha + \beta)^2} \; .\]

Proof: The variance can be expressed in terms of expected values as

\[\label{eq:var-mean} \mathrm{Var}(X) = \mathrm{E}(X^2) - \mathrm{E}(X)^2 \; .\]

The expected value of a beta random variable is

\[\label{eq:beta-mean} \mathrm{E}(X) = \frac{\alpha}{\alpha+\beta} \; .\]

The probability density function of the beta distribution is

\[\label{eq:beta-pdf} f_X(x) = \frac{1}{\mathrm{B}(\alpha, \beta)} \, x^{\alpha-1} \, (1-x)^{\beta-1}, \quad 0 \leq x \leq 1\]

where the beta function is given by a ratio gamma functions:

\[\label{eq:beta-fct} \mathrm{B}(\alpha, \beta) = \frac{\Gamma(\alpha) \cdot \Gamma(\beta)}{\Gamma(\alpha+\beta)} \; .\]

Therefore, the expected value of a squared beta random variable becomes

\[\label{eq:beta-sqr-mean-s1} \begin{split} \mathrm{E}(X^2) &= \int_{0}^{1} x^2 \cdot \frac{\Gamma(\alpha+\beta)}{\Gamma(\alpha) \cdot \Gamma(\beta)} \, x^{\alpha-1} \, (1-x)^{\beta-1} \, \mathrm{d}x \\ &= \frac{\Gamma(\alpha+\beta)}{\Gamma(\alpha)} \cdot \frac{\Gamma(\alpha+2)}{\Gamma(\alpha+2+\beta)} \int_{0}^{1} \frac{\Gamma(\alpha+2+\beta)}{\Gamma(\alpha+2) \cdot \Gamma(\beta)} \, x^{(\alpha+2)-1} \, (1-x)^{\beta-1} \, \mathrm{d}x \; . \end{split}\]

Twice-applying the relation $\Gamma(x+1) = \Gamma(x) \cdot x$, we have

\[\label{eq:beta-sqr-mean-s2} \begin{split} \mathrm{E}(X^2) &= \frac{\Gamma(\alpha+\beta)}{\Gamma(\alpha)} \cdot \frac{(\alpha+1) \cdot \alpha \cdot \Gamma(\alpha)}{(\alpha+\beta+1) \cdot (\alpha+\beta) \cdot \Gamma(\alpha+\beta)} \int_{0}^{1} \frac{\Gamma(\alpha+2+\beta)}{\Gamma(\alpha+2) \cdot \Gamma(\beta)} \, x^{(\alpha+2)-1} \, (1-x)^{\beta-1} \, \mathrm{d}x \\ &= \frac{(\alpha+1) \cdot \alpha}{(\alpha+\beta+1) \cdot (\alpha+\beta)} \int_{0}^{1} \frac{\Gamma(\alpha+2+\beta)}{\Gamma(\alpha+2) \cdot \Gamma(\beta)} \, x^{(\alpha+2)-1} \, (1-x)^{\beta-1} \, \mathrm{d}x \end{split}\]

and again using the density of the beta distribution, we get

\[\label{eq:beta-sqr-mean-s3} \begin{split} \mathrm{E}(X^2) &= \frac{(\alpha+1) \cdot \alpha}{(\alpha+\beta+1) \cdot (\alpha+\beta)} \int_{0}^{1} \mathrm{Bet}(x; \alpha+2, \beta) \, \mathrm{d}x \\ &= \frac{(\alpha+1) \cdot \alpha}{(\alpha+\beta+1) \cdot (\alpha+\beta)} \; . \end{split}\]

Plugging \eqref{eq:beta-sqr-mean-s3} and \eqref{eq:beta-mean} into \eqref{eq:var-mean}, the variance of a beta random variable finally becomes

\[\label{eq:beta-var-qed} \begin{split} \mathrm{Var}(X) &= \frac{(\alpha+1) \cdot \alpha}{(\alpha+\beta+1) \cdot (\alpha+\beta)} - \left( \frac{\alpha}{\alpha+\beta} \right)^2 \\ &= \frac{(\alpha^2+\alpha) \cdot (\alpha + \beta)}{(\alpha + \beta + 1) \cdot (\alpha + \beta)^2} - \frac{\alpha^2 \cdot (\alpha + \beta + 1)}{(\alpha + \beta + 1) \cdot (\alpha + \beta)^2} \\ &= \frac{(\alpha^3 + \alpha^2 \beta + \alpha^2 + \alpha \beta) - (\alpha^3 + \alpha^2 \beta + \alpha^2)}{(\alpha + \beta + 1) \cdot (\alpha + \beta)^2} \\ &= \frac{\alpha \beta}{(\alpha + \beta + 1) \cdot (\alpha + \beta)^2} \; . \end{split}\]
Sources:

Metadata: ID: P229 | shortcut: beta-var | author: JoramSoch | date: 2021-04-29, 09:31.