Truncated normal distribution

Notation Probability density function Probability density function for the truncated normal distribution for different sets of parameters. In all cases, a = −10 and b = 10. For the black: μ = −8, σ = 2; blue: μ = 0, σ = 2; red: μ = 9, σ = 10; orange: μ = 0, σ = 10. Cumulative distribution function Cumulative distribution function for the truncated normal distribution for different sets of parameters. In all cases, a = −10 and b = 10. For the black: μ = −8, σ = 2; blue: μ = 0, σ = 2; red: μ = 9, σ = 10; orange: μ = 0, σ = 10. $\xi=\frac{x-\mu}{\sigma},\ \alpha=\frac{a-\mu}{\sigma},\ \beta=\frac{b-\mu}{\sigma}$ $Z=\Phi(\beta)-\Phi(\alpha)$ μ ∈ R — mean (location) σ2 ≥ 0 — variance (squared scale) a ∈ R — minimum value b ∈ R — maximum value x ∈ a,b $f(x;\mu,\sigma, a,b) = \frac{1}{\sigma Z}\phi(\xi)$ $F(x;\mu,\sigma, a,b) = \frac{\Phi(\xi) - \Phi(\alpha)}{Z}$ $\mu + \frac{\phi(\alpha)-\phi(\beta)}{Z}\sigma$ $\left\{\begin{array}{ll}a, & \mathrm{if}\ \mub\end{array}\right.$ $\sigma^2\left[1+\frac{\alpha\phi(\alpha)-\beta\phi(\beta)}{Z} -\left(\frac{\phi(\alpha)-\phi(\beta)}{Z}\right)^2\right]$ $\ln(\sqrt{2 \pi e} \sigma Z)+ \dots$ $\dots + \frac{\alpha\phi(\alpha)-\beta\phi(\beta)}{2Z}-\frac{(\phi(\alpha)-\phi(\beta))^2}{2Z^2}$

In probability and statistics, the truncated normal distribution is the probability distribution of a normally distributed random variable whose value is either bounded below or above (or both). The truncated normal distribution has wide applications in statistics and econometrics. For example, it is used to model the probabilities of the binary outcomes in the probit model and to model censored data in the Tobit model.

Definition

Suppose $X \sim N(\mu, \sigma^{2}) \!$ has a normal distribution and lies within the interval $X \in (a,b), \; -\infty \leq a < b \leq \infty$. Then $X$ conditional on $a < X < b$ has a truncated normal distribution.

Its probability density function, ƒ, for axb, is given by

$f(x;\mu,\sigma,a,b) = \frac{\frac{1}{\sigma}\phi(\frac{x - \mu}{\sigma})}{\Phi(\frac{b - \mu}{\sigma}) - \Phi(\frac{a - \mu}{\sigma}) }$

and by ƒ=0 otherwise.

Here, $\scriptstyle{\phi(\xi)=\frac{1}{\sqrt{2 \pi}}\exp{(-\frac{1}{2}\xi^2})} \$ is the probability density function of the standard normal distribution and $\scriptstyle{\Phi(\cdot)} \$ is its cumulative distribution function. There is an understanding that if $\scriptstyle{b=\infty} \$, then $\scriptstyle{\Phi(\frac{b - \mu}{\sigma}) =1}$, and similarly, if $\scriptstyle{a=-\infty} \$, then $\scriptstyle{\Phi(\frac{a - \mu}{\sigma}) =0}$.

Moments

Two sided truncation:1

$\operatorname{E}(X \mid a
$\operatorname{Var}(X \mid a

One sided truncation (upper tail):2

$\operatorname{E}(X \mid X>a) = \mu +\sigma\lambda(\alpha) \!$
$\operatorname{Var}(X \mid X>a) = \sigma^2[1-\delta(\alpha)],\!$

where $\alpha=(a-\mu)/\sigma,\; \lambda(\alpha)=\phi(\alpha)/[1-\Phi(\alpha)]\;$ and $\; \delta(\alpha) = \lambda(\alpha)[\lambda(\alpha)-\alpha]$.

One sided truncation (lower tail):

$\operatorname{E}(X \mid X
$\operatorname{Var}(X \mid X

where $\beta=(b-\mu)/\sigma.$

Simulating

A random variate x defined as $x = \Phi^{-1}( \Phi(\alpha) + U * (\Phi(\beta)-\Phi(\alpha)))\sigma + \mu$ with $\Phi$ the cumulative distribution function and $\Phi^{-1}$ its inverse, $U$ a uniform random number on $(0, 1)$, follows the distribution truncated to the range $(a, b)$.

For more on simulating a draw from the truncated normal distribution, see Robert (1995), Lynch (2007) Section 8.1.3 (pages 200–206), Devroye (1986). The MSM package in R has a function, rtnorm, that calculates draws from a truncated normal. The truncnorm package in R also has functions to draw from a truncated normal.