Week 8: Common Families of Distributions

Reading: Casella & Berger (C&B) §§3.3–3.5

Lecture Date Topics C&B
8.1 Tue. Nov. 17 Continuous families: normal, beta, Cauchy, lognormal, double exponential; exponential families §§3.3–3.4
8.2 Thu. Nov. 19 Location and scale families §3.5

Notation.

  • Parameters are written after a “$\mid$”: $f(x \mid \mu, \sigma^2)$. A possibly vector-valued parameter is $\boldsymbol{\theta}$, and the set of its possible values (the parameter space) is $\Theta$.
  • $\mathrm{n}(\mu, \sigma^2)$ is the normal distribution with mean $\mu$ and variance $\sigma^2$ (C&B’s notation). $Z$ usually denotes a $\mathrm{n}(0, 1)$ random variable.
  • $\Gamma(\alpha) = \int_0^{\infty} t^{\alpha - 1} e^{-t}\, dt$ is the gamma function, and $B(\alpha, \beta) = \int_0^1 x^{\alpha - 1}(1 - x)^{\beta - 1}\, dx$ is the beta function (§2).
  • $I_A(x)$ is the indicator function of the set $A$ (Definition 3.4.5).
  • $\boldsymbol{\eta} = (\eta_1, \dots, \eta_k)$ is the natural parameter of an exponential family (§6).

Where we are. Last week covered the discrete families and the uniform and gamma families.

  1. What do many families have in common? Their pmfs and pdfs factor in the same exponential form (§3.4), which gives moments by differentiation.
  2. How do we build a family from one pdf? Shift it and stretch it (§3.5).

Inequalities and identities (§3.6) are in the Week 9 notes.


Continuous Families, Continued

Way of thinking. Recognize a kernel to evaluate integrals, and standardize to reduce a family to one member.

Recap: the gamma family. Last week’s gamma($\alpha$, $\beta$) pdf (3.3.6) is $f(x \mid \alpha, \beta) = x^{\alpha - 1} e^{-x/\beta} / (\Gamma(\alpha) \beta^{\alpha})$ for $x > 0$, with $\mathrm{E}X = \alpha\beta$ and $\mathrm{Var}\, X = \alpha\beta^2$. The two parameters play different roles.

left: gamma densities with scale 1 and shapes 0.5, 1, 2, 5; right: gamma densities with shape 3 and scales 0.5, 1, 2, 4

  • Left: the shape $\alpha$ changes the form of the pdf. As with the beta, the exponent $\alpha - 1$ controls the behavior near 0. For $\alpha < 1$ the pdf is infinite at 0 and decreasing. For $\alpha = 1$ it is the exponential, with $f(0) = 1/\beta$. For $\alpha > 1$ it starts at 0 and has its mode at $(\alpha - 1)\beta$. As $\alpha$ grows the pdf becomes more symmetric, which anticipates the normal approximation (a gamma with integer $\alpha$ is a sum of $\alpha$ independent exponentials, Chapter 4).
  • Right: the scale $\beta$ only stretches the $x$-axis. All four curves have the same shape. If $T \sim$ gamma($\alpha$, 1), then $X = \beta T \sim$ gamma($\alpha$, $\beta$), so doubling $\beta$ doubles the mean, quadruples the variance, and halves the height of the pdf. This is the scale-family idea of §7.

1. Normal distribution

The normal distribution (sometimes called the Gaussian distribution) plays a central role in a large body of statistics. There are three main reasons for this.

  1. The normal distribution and distributions associated with it are very tractable analytically (although this may not seem so at first glance).
  2. The normal distribution has the familiar bell shape, whose symmetry makes it an appealing choice for many population models. Although there are many other distributions that are also bell-shaped, most do not possess the analytic tractability of the normal.
  3. There is the Central Limit Theorem (see Chapter 5 for details), which shows that, under mild conditions, the normal distribution can be used to approximate a large variety of distributions in large samples.

The normal distribution has two parameters, usually denoted by $\mu$ and $\sigma^2$, which are its mean and variance. The pdf of the normal distribution with mean $\mu$ and variance $\sigma^2$ (usually denoted by $\mathrm{n}(\mu, \sigma^2)$) is given by

\[f(x \mid \mu, \sigma^2) = \frac{1}{\sqrt{2\pi}\, \sigma} e^{-(x - \mu)^2/(2\sigma^2)}, \quad -\infty < x < \infty. \tag{3.3.13}\]

Standardizing. If $X \sim \mathrm{n}(\mu, \sigma^2)$, then the random variable $Z = (X - \mu)/\sigma$ has a $\mathrm{n}(0, 1)$ distribution, also known as the standard normal. This is easily established by writing

\[\begin{aligned} P(Z \le z) &= P\left( \frac{X - \mu}{\sigma} \le z \right) \\ &= P(X \le z\sigma + \mu) \\ &= \frac{1}{\sqrt{2\pi}\, \sigma} \int_{-\infty}^{z\sigma + \mu} e^{-(x - \mu)^2/(2\sigma^2)}\, dx \\ &= \frac{1}{\sqrt{2\pi}} \int_{-\infty}^{z} e^{-t^2/2}\, dt, && \left( \text{substitute } t = \frac{x - \mu}{\sigma} \right) \end{aligned}\]

showing that $P(Z \le z)$ is the standard normal cdf.

  • It therefore follows that all normal probabilities can be calculated in terms of the standard normal.
  • Furthermore, calculations of expected values can be simplified by carrying out the details in the $\mathrm{n}(0, 1)$ case, then transforming the result to the $\mathrm{n}(\mu, \sigma^2)$ case. For example, if $Z \sim \mathrm{n}(0, 1)$,

    \[\mathrm{E}Z = \frac{1}{\sqrt{2\pi}} \int_{-\infty}^{\infty} z e^{-z^2/2}\, dz = 0,\]

    and so, if $X \sim \mathrm{n}(\mu, \sigma^2)$, it follows from Theorem 2.2.5 that

    \[\mathrm{E}X = \mathrm{E}(\mu + \sigma Z) = \mu + \sigma \mathrm{E}Z = \mu.\]
  • Similarly, we have that $\mathrm{Var}\, Z = 1$ and, from Theorem 2.3.4, $\mathrm{Var}\, X = \sigma^2$.
  • The mgf is $M_X(t) = e^{\mu t + \sigma^2 t^2/2}$ for all $t$ (Exercise 2.33).

The pdf integrates to 1. We have not yet established that (3.3.13) integrates to 1 over the whole real line. By applying the standardizing transformation, we need only to show that

\[\frac{1}{\sqrt{2\pi}} \int_{-\infty}^{\infty} e^{-z^2/2}\, dz = 1.\]

Notice that the integrand above is symmetric around 0, implying that the integral over $(-\infty, 0)$ is equal to the integral over $(0, \infty)$. Thus, we reduce the problem to showing

\[\int_0^{\infty} e^{-z^2/2}\, dz = \frac{\sqrt{2\pi}}{2} = \sqrt{\frac{\pi}{2}}. \tag{3.3.14}\]
  • The function $e^{-z^2/2}$ does not have an antiderivative that can be written explicitly in terms of elementary functions (that is, in closed form), so we cannot perform the integration directly.
  • In fact, this is an example of an integration that either you know how to do or else you can spend a very long time going nowhere.
  • Since both sides of (3.3.14) are positive, the equality will hold if we establish that the squares are equal.

Square the integral in (3.3.14) to obtain

\[\begin{aligned} \left( \int_0^{\infty} e^{-z^2/2}\, dz \right)^2 &= \left( \int_0^{\infty} e^{-t^2/2}\, dt \right) \left( \int_0^{\infty} e^{-u^2/2}\, du \right) \\ &= \int_0^{\infty} \int_0^{\infty} e^{-(t^2 + u^2)/2}\, dt\, du. \end{aligned}\]

The integration variables are just dummy variables, so changing their names is allowed. Now, we convert to polar coordinates. Define

\[t = r\cos\theta \quad \text{and} \quad u = r\sin\theta.\]

Then $t^2 + u^2 = r^2$ and $dt\, du = r\, d\theta\, dr$ and the limits of integration become $0 < r < \infty$, $0 < \theta < \pi/2$ (the upper limit on $\theta$ is $\pi/2$ because $t$ and $u$ are restricted to be positive). We now have

\[\begin{aligned} \int_0^{\infty} \int_0^{\infty} e^{-(t^2 + u^2)/2}\, dt\, du &= \int_0^{\infty} \int_0^{\pi/2} r e^{-r^2/2}\, d\theta\, dr \\ &= \frac{\pi}{2} \int_0^{\infty} r e^{-r^2/2}\, dr \\ &= \frac{\pi}{2} \Big[ -e^{-r^2/2} \Big\rvert_0^{\infty} \Big] \\ &= \frac{\pi}{2}, \end{aligned}\]

which establishes (3.3.14).

This integral is closely related to the gamma function; in fact, by making the substitution $w = \frac{1}{2} z^2$ in (3.3.14), we see that this integral is essentially $\Gamma(\frac{1}{2})$. If we are careful to get the constants correct, we will see that (3.3.14) implies

\[\Gamma\left( \frac{1}{2} \right) = \int_0^{\infty} w^{-1/2} e^{-w}\, dw = \sqrt{\pi}. \tag{3.3.15}\]

Shape and probability content.

  • The normal distribution is somewhat special in the sense that its two parameters, $\mu$ (the mean) and $\sigma^2$ (the variance), provide us with complete information about the exact shape and location of the distribution. This property is not unique to the normal pdf, but is shared by a family of pdfs called location–scale families, to be discussed in Section 3.5 (§7).
  • Straightforward calculus shows that the normal pdf (3.3.13) has its maximum at $x = \mu$ and inflection points (where the curve changes from concave to convex) at $\mu \pm \sigma$.
  • The probability content within 1, 2, or 3 standard deviations of the mean is

    \[\begin{aligned} P(\lvert X - \mu \rvert \le \sigma) &= P(\lvert Z \rvert \le 1) = .6826, \\ P(\lvert X - \mu \rvert \le 2\sigma) &= P(\lvert Z \rvert \le 2) = .9544, \\ P(\lvert X - \mu \rvert \le 3\sigma) &= P(\lvert Z \rvert \le 3) = .9974, \end{aligned}\]

    where $X \sim \mathrm{n}(\mu, \sigma^2)$, $Z \sim \mathrm{n}(0, 1)$. Often, the two-digit values reported are .68, .95, and .99, respectively. Although these do not represent the rounded values, they are the values commonly used.

The normal approximation to the binomial. Among the many uses of the normal distribution, an important one is its use as an approximation to other distributions (which is partially justified by the Central Limit Theorem).

  • If $X \sim$ binomial($n$, $p$), then $\mathrm{E}X = np$ and $\mathrm{Var}\, X = np(1 - p)$, and under suitable conditions, the distribution of $X$ can be approximated by that of a normal random variable with mean $\mu = np$ and variance $\sigma^2 = np(1 - p)$.
  • The “suitable conditions” are that $n$ should be large and $p$ should not be extreme (near 0 or 1).
    • We want $n$ large so that there are enough (discrete) values of $X$ to make an approximation by a continuous distribution reasonable.
    • $p$ should be “in the middle” so the binomial is nearly symmetric, as is the normal.
  • As with most approximations there are no absolute rules. A conservative rule to follow is that the approximation will be good if $\min(np, n(1 - p)) \ge 5$.
  • Compare the Poisson approximation (last week, §5), which is for $n$ large and $p$ small.

Example 3.3.2 (Normal approximation). Let $X \sim$ binomial$(25, .6)$. We can approximate $X$ with a normal random variable, $Y$, with mean $\mu = 25(.6) = 15$ and standard deviation $\sigma = ((25)(.6)(.4))^{1/2} = 2.45$. Thus

\[\begin{aligned} P(X \le 13) \approx P(Y \le 13) &= P\left( Z \le \frac{13 - 15}{2.45} \right) \\ &= P(Z \le -.82) = .206, \end{aligned}\]

while the exact binomial calculation gives

\[P(X \le 13) = \sum_{x=0}^{13} \binom{25}{x} (.6)^x (.4)^{25 - x} = .267,\]

showing that the normal approximation is good, but not terrific. The approximation can be greatly improved, however, by a “continuity correction.”

  • In the figure below, the binomial pmf is drawn using bars of width 1, with height equal to the probability. Thus, the areas of the bars give the binomial probabilities.
  • Notice how the area of the approximating normal is smaller than the binomial area: the normal area is everything to the left of the line at 13, whereas the binomial area includes the entire bar at 13 up to 13.5.
  • The continuity correction adds this area back by adding $\frac{1}{2}$ to the cutoff point. So instead of approximating $P(X \le 13)$, we approximate the equivalent expression (because of the discreteness), $P(X \le 13.5)$ and obtain

    \[\begin{aligned} P(X \le 13) &= P(X \le 13.5) \approx P(Y \le 13.5) \\ &= P(Z \le -.61) = .271, \end{aligned}\]

    a much better approximation.

binomial(25, 0.6) pmf as bars with the n(15, 2.45^2) pdf, cutoffs at 13 and 13.5

Figure (C&B Figure 3.3.2). The bars at $x \le 13$ (dark) have total area $.267$. The normal area to the left of 13 misses the right half of the bar at 13; cutting at 13.5 recovers it.

In general, the normal approximation with the continuity correction is far superior to the approximation without the continuity correction. We also make the correction on the lower end. If $X \sim$ binomial($n$, $p$) and $Y \sim \mathrm{n}(np, np(1 - p))$, then we approximate

\[\begin{aligned} P(X \le x) &\approx P(Y \le x + 1/2), \\ P(X \ge x) &\approx P(Y \ge x - 1/2). \end{aligned}\]

2. Beta distribution

The beta family of distributions is a continuous family on $(0, 1)$ indexed by two parameters. The beta($\alpha$, $\beta$) pdf is

\[f(x \mid \alpha, \beta) = \frac{1}{B(\alpha, \beta)} x^{\alpha - 1} (1 - x)^{\beta - 1}, \quad 0 < x < 1, \quad \alpha > 0, \quad \beta > 0, \tag{3.3.16}\]

where $B(\alpha, \beta)$ denotes the beta function,

\[B(\alpha, \beta) = \int_0^1 x^{\alpha - 1} (1 - x)^{\beta - 1}\, dx.\]

left: beta densities of four shapes; right: symmetric beta densities concentrating around one half as alpha grows

Figure (compare C&B Figures 3.3.3 and 3.3.4). Left: beta($\alpha$, $\beta$) densities, labeled by $(\alpha, \beta)$. The exponents $\alpha - 1$ and $\beta - 1$ control the behavior near 0 and near 1: an exponent below 0 sends the pdf to $\infty$ at that end, and an exponent above 0 sends it to 0. Right: symmetric beta($\alpha$, $\alpha$) densities. The mean stays at $\frac{1}{2}$ while the variance $(4(2\alpha + 1))^{-1}$ shrinks, so the mass piles up around $\frac{1}{2}$.

The beta function is related to the gamma function through the following identity:

\[B(\alpha, \beta) = \frac{\Gamma(\alpha) \Gamma(\beta)}{\Gamma(\alpha + \beta)}. \tag{3.3.17}\]
  • Equation (3.3.17) is very useful in dealing with the beta function, allowing us to take advantage of the properties of the gamma function. In fact, we will never deal directly with the beta function, but rather will use (3.3.17) for all of our evaluations.
  • The beta distribution is one of the few common “named” distributions that give probability 1 to a finite interval, here taken to be $(0, 1)$. As such, the beta is often used to model proportions, which naturally lie between 0 and 1. We will see illustrations of this in Chapter 4.

Moments. Calculation of moments of the beta distribution is quite easy, due to the particular form of the pdf. For $n > -\alpha$ we have

\[\begin{aligned} \mathrm{E}X^n &= \frac{1}{B(\alpha, \beta)} \int_0^1 x^n x^{\alpha - 1} (1 - x)^{\beta - 1}\, dx \\ &= \frac{1}{B(\alpha, \beta)} \int_0^1 x^{(\alpha + n) - 1} (1 - x)^{\beta - 1}\, dx. \end{aligned}\]

We now recognize the integrand as the kernel of a beta$(\alpha + n, \beta)$ pdf; hence,

\[\mathrm{E}X^n = \frac{B(\alpha + n, \beta)}{B(\alpha, \beta)} = \frac{\Gamma(\alpha + n) \Gamma(\alpha + \beta)}{\Gamma(\alpha + \beta + n) \Gamma(\alpha)}. \tag{3.3.18}\]

Using (3.3.3) and (3.3.18) with $n = 1$ and $n = 2$, we calculate the mean and variance of the beta($\alpha$, $\beta$) distribution as

\[\mathrm{E}X = \frac{\alpha}{\alpha + \beta} \quad \text{and} \quad \mathrm{Var}\, X = \frac{\alpha\beta}{(\alpha + \beta)^2 (\alpha + \beta + 1)}.\]

Shapes. As the parameters $\alpha$ and $\beta$ vary, the beta distribution takes on many shapes, as shown in the left panel of the figure below. The pdf can be

  • strictly increasing ($\alpha > 1$, $\beta = 1$),
  • strictly decreasing ($\alpha = 1$, $\beta > 1$),
  • U-shaped ($\alpha < 1$, $\beta < 1$), or
  • unimodal ($\alpha > 1$, $\beta > 1$).

The case $\alpha = \beta$ yields a pdf symmetric about $\frac{1}{2}$ with mean $\frac{1}{2}$ (necessarily) and variance $(4(2\alpha + 1))^{-1}$. The pdf becomes more concentrated as $\alpha$ increases, but stays symmetric. Finally, if $\alpha = \beta = 1$, the beta distribution reduces to the uniform(0, 1), showing that the uniform can be considered to be a member of the beta family. The beta distribution is also related, through a transformation, to the $F$ distribution, a distribution that plays an extremely important role in statistical analysis (see Section 5.3).

3. Cauchy distribution

The Cauchy distribution is a symmetric, bell-shaped distribution on $(-\infty, \infty)$ with pdf

\[f(x \mid \theta) = \frac{1}{\pi} \frac{1}{1 + (x - \theta)^2}, \quad -\infty < x < \infty, \quad -\infty < \theta < \infty. \tag{3.3.19}\]

(See Exercise 3.39 for a more general version of the Cauchy pdf.)

  • To the eye, the Cauchy does not appear very different from the normal distribution.
  • However, there is a very great difference, indeed. As we have already seen in Chapter 2 (Example 2.2.4), the mean of the Cauchy distribution does not exist; that is,
\[\mathrm{E}\lvert X \rvert = \int_{-\infty}^{\infty} \frac{1}{\pi} \frac{\lvert x \rvert}{1 + (x - \theta)^2}\, dx = \infty. \tag{3.3.20}\]

It is easy to see that (3.3.19) defines a proper pdf for all $\theta$. Recall that $\frac{d}{dt} \arctan(t) = (1 + t^2)^{-1}$; hence,

\[\int_{-\infty}^{\infty} \frac{1}{\pi} \frac{1}{1 + (x - \theta)^2}\, dx = \frac{1}{\pi} \arctan(x - \theta) \Big\rvert_{-\infty}^{\infty} = 1,\]

since $\arctan(\pm\infty) = \pm\pi/2$.

  • Since $\mathrm{E}\lvert X \rvert = \infty$, it follows that no moments of the Cauchy distribution exist or, in other words, all absolute moments equal $\infty$. In particular, the mgf does not exist.
  • The parameter $\theta$ in (3.3.19) does measure the center of the distribution; it is the median. If $X$ has a Cauchy distribution with parameter $\theta$, then from Exercise 3.37 it follows that $P(X \ge \theta) = \frac{1}{2}$, showing that $\theta$ is the median of the distribution.
  • The Cauchy distribution plays a special role in the theory of statistics. It represents an extreme case against which conjectures can be tested.
  • But do not make the mistake of considering the Cauchy distribution to be only a pathological case, for it has a way of turning up when you least expect it.
  • For example, it is common practice for experimenters to calculate ratios of observations, that is, ratios of random variables. A surprising fact is that the ratio of two standard normals has a Cauchy distribution (see Example 4.3.6). Taking ratios can lead to ill-behaved distributions.

Normal versus Cauchy, in pictures. The figure below makes the difference concrete.

left: standard normal and Cauchy densities; middle: tail probabilities on a log scale; right: running means of simulated normal and Cauchy draws

  • Left (C&B Figure 3.3.5). Near 0 the two densities look alike: both are symmetric and bell-shaped. The Cauchy is lower in the middle and higher in the tails.
  • Middle. The tails differ by orders of magnitude. $P(\lvert Z \rvert > 3) = .0027$ for the normal, but $P(\lvert X \rvert > 3) = .205$ for the Cauchy. The Cauchy tail is

    \[P(\lvert X \rvert > t) = 1 - \frac{2}{\pi} \arctan t = \frac{2}{\pi} \arctan\left( \frac{1}{t} \right) \approx \frac{2}{\pi t} \quad \text{for large } t,\]

    which decays only like $1/t$, while the normal tail decays like $e^{-t^2/2}$ (see (3.6.1) in the Week 9 notes). With the tail formula $\mathrm{E}\lvert X \rvert = \int_0^{\infty} P(\lvert X \rvert > t)\, dt$ (Homework 3, Problem 4), a $1/t$ tail gives $\mathrm{E}\lvert X \rvert = \infty$, which is (3.3.20) again.

  • Right. The running mean $\bar{x}_n$, the average of the first $n$ of $10{,}000$ simulated draws (seed 201; script figs/week8_families.py). The normal running mean settles at 0. The Cauchy running mean keeps jumping, because now and then a single draw is so large that it moves the average of thousands of earlier draws. The law of large numbers (Chapter 5) needs $\mathrm{E}\lvert X \rvert < \infty$, and the Cauchy does not have it.

4. Lognormal and double exponential distributions (Optional)

There are many other continuous distributions that have uses in different statistical applications.

Check your understanding.

  1. Let $X \sim$ beta(3, 2). Use (3.3.18) to find $\mathrm{E}X$, $\mathrm{Var}\, X$, and $\mathrm{E}(1/X)$.

    Show answer

    $\mathrm{E}X = \frac{\alpha}{\alpha + \beta} = \frac{3}{5}$ and

    \[\mathrm{Var}\, X = \frac{\alpha\beta}{(\alpha + \beta)^2 (\alpha + \beta + 1)} = \frac{6}{25 \cdot 6} = \frac{1}{25}.\]

    For $\mathrm{E}(1/X)$, take $n = -1$, which is allowed since $-1 > -\alpha = -3$:

    \[\mathrm{E}X^{-1} = \frac{\Gamma(\alpha - 1) \Gamma(\alpha + \beta)}{\Gamma(\alpha + \beta - 1) \Gamma(\alpha)} = \frac{\alpha + \beta - 1}{\alpha - 1} = \frac{4}{2} = 2,\]

    using (3.3.3) twice: $\Gamma(\alpha + \beta) = (\alpha + \beta - 1)\Gamma(\alpha + \beta - 1)$ and $\Gamma(\alpha) = (\alpha - 1)\Gamma(\alpha - 1)$. Note $\mathrm{E}(1/X) = 2 \ne 1/\mathrm{E}X = \frac{5}{3}$.

  2. Let $X \sim$ binomial(100, .5). Approximate $P(X \le 45)$ with the normal approximation, with and without the continuity correction. (The exact value is .184.)

    Show answer

    $\mu = np = 50$ and $\sigma = \sqrt{100(.5)(.5)} = 5$. Here $\min(np, n(1 - p)) = 50 \ge 5$, so the approximation should be good.

    • Without correction: $P(Y \le 45) = P(Z \le -1) = .159$.
    • With correction: $P(Y \le 45.5) = P(Z \le -.9) = .184$, which matches the exact value to three digits.
  3. Let $X \sim$ Cauchy(0). Show that $t \, P(\lvert X \rvert > t) \to 2/\pi$ as $t \to \infty$. What does this say about $\mathrm{E}\lvert X \rvert$?

    Show answer

    By symmetry and $\int_t^{\infty} \frac{dx}{\pi(1 + x^2)} = \frac{1}{\pi}\left( \frac{\pi}{2} - \arctan t \right)$,

    \[P(\lvert X \rvert > t) = 1 - \frac{2}{\pi} \arctan t = \frac{2}{\pi} \arctan\left( \frac{1}{t} \right),\]

    using $\arctan t + \arctan(1/t) = \pi/2$ for $t > 0$. Since $\arctan(u)/u \to 1$ as $u \to 0$, $t \, P(\lvert X \rvert > t) = \frac{2}{\pi} \cdot \frac{\arctan(1/t)}{1/t} \to \frac{2}{\pi}$.

    So $P(\lvert X \rvert > t) \ge \frac{1}{\pi t}$ for all large $t$, say $t \ge t_0$, and

    \[\mathrm{E}\lvert X \rvert = \int_0^{\infty} P(\lvert X \rvert > t)\, dt \ge \int_{t_0}^{\infty} \frac{1}{\pi t}\, dt = \infty.\]

Exponential Families

Way of thinking. Recognize the structure of a pdf. Sort its pieces into three piles: what depends only on $x$, what depends only on $\boldsymbol{\theta}$, and what links the two.

The same form keeps turning up in science and data analysis.

  • Physics: the Boltzmann distribution. A system in thermal equilibrium at temperature $T$ is in a state with energy $E$ with probability proportional to $e^{-E/(kT)}$, where $k$ is Boltzmann’s constant. This is the form $e^{\eta\, t(x)}$ with $t(x)$ equal to the energy of state $x$ and $\eta = -1/(kT)$. For example, an air molecule at height $x$ has potential energy $mgx$, so in an atmosphere at constant temperature its height has density proportional to $e^{-mgx/(kT)}$. That is an exponential distribution with $\beta = kT/(mg)$, about 8 km for Earth’s air: the atmosphere thins by a factor of $e$ every 8 km or so.
  • Regression: generalized linear models. Logistic regression models a yes/no outcome (has the disease, clicks the ad) as Bernoulli($p$) and sets the natural parameter, the log odds $\log \frac{p}{1 - p}$, equal to a linear function of covariates. Poisson regression does the same for counts (insurance claims, hospital visits) with $\log \lambda$. Nelder and Wedderburn (1972) built the whole class of generalized linear models on exponential families for this reason: the natural parameter is the scale on which a linear model makes sense.
  • Machine learning: softmax. A neural network classifier with $K$ classes outputs scores $\eta_1, \dots, \eta_K$ (the “logits”) and predicts class $j$ with probability $e^{\eta_j} / \sum_{k=1}^K e^{\eta_k}$. This is a multinomial exponential family with natural parameters $\eta_j$.
  • Maximum entropy. Among all pdfs on $(0, \infty)$ with a given mean, the exponential has the largest entropy; among all pdfs on $(-\infty, \infty)$ with a given mean and variance, the normal does. In general, the distribution that is “most spread out” subject to fixing $\mathrm{E}\, t_1(X), \dots, \mathrm{E}\, t_k(X)$ is an exponential family in $t_1, \dots, t_k$ (Jaynes 1957). Exponential families are what you get when you assume the constraints and nothing more.

What to look for in the definition. The definition below has four pieces: $h(x)$ depends only on $x$, $c(\boldsymbol{\theta})$ depends only on the parameter and is the normalizing constant, and $x$ and $\boldsymbol{\theta}$ meet only through products $w_i(\boldsymbol{\theta})\, t_i(x)$ inside one exponential. That last feature is what made the Poisson mgf above so easy.

5. Definition and moments

A family of pdfs or pmfs is called an exponential family if it can be expressed as

\[f(x \mid \boldsymbol{\theta}) = h(x)\, c(\boldsymbol{\theta}) \exp\left( \sum_{i=1}^k w_i(\boldsymbol{\theta})\, t_i(x) \right). \tag{3.4.1}\]
  • $h(x) \ge 0$ and $t_1(x), \dots, t_k(x)$ are real-valued functions of the observation $x$ (they cannot depend on $\boldsymbol{\theta}$).
  • $c(\boldsymbol{\theta}) \ge 0$ and $w_1(\boldsymbol{\theta}), \dots, w_k(\boldsymbol{\theta})$ are real-valued functions of the possibly vector-valued parameter $\boldsymbol{\theta}$ (they cannot depend on $x$).
  • Many common families are exponential families: the continuous families normal, gamma, and beta, and the discrete families binomial, Poisson, and negative binomial (with $r$ known).

To verify that a family of pdfs or pmfs is an exponential family, we must identify the functions $h(x)$, $c(\boldsymbol{\theta})$, $w_i(\boldsymbol{\theta})$, and $t_i(x)$ and show that the family has the form (3.4.1).

Example 3.4.1 (Binomial exponential family). Let $n$ be a positive integer and consider the binomial($n$, $p$) family with $0 < p < 1$. Then the pmf for this family, for $x = 0, \dots, n$ and $0 < p < 1$, is

\[\begin{aligned} f(x \mid p) &= \binom{n}{x} p^x (1 - p)^{n - x} \\ &= \binom{n}{x} (1 - p)^n \left( \frac{p}{1 - p} \right)^x \\ &= \binom{n}{x} (1 - p)^n \exp\left( \log\left( \frac{p}{1 - p} \right) x \right). \end{aligned} \tag{3.4.2}\]

Define

\[h(x) = \begin{cases} \binom{n}{x} & x = 0, \dots, n \\ 0 & \text{otherwise,} \end{cases} \qquad c(p) = (1 - p)^n, \qquad w_1(p) = \log\left( \frac{p}{1 - p} \right), \qquad t_1(x) = x.\]

Then $f(x \mid p) = h(x) c(p) \exp[w_1(p) t_1(x)]$, which is of the form (3.4.1) with $k = 1$.

  • The functions must match (3.4.2) for all values of $x$, so $h(x)$ carries the support: $h(x) > 0$ only if $x = 0, \dots, n$.
  • The family is an exponential family only for $0 < p < 1$, where $c(p)$ and $w_1(p)$ are defined. The values $p = 0$ and $1$ are excluded because there the set of $x$ with $f(x \mid p) > 0$ changes.
  • $w_1(p) = \log(p/(1 - p))$ is the log odds, which will reappear as the logistic regression link.

Theorem 3.4.2. If $X$ is a random variable with pdf or pmf of the form (3.4.1), then

\[\mathrm{E}\left( \sum_{i=1}^k \frac{\partial w_i(\boldsymbol{\theta})}{\partial \theta_j} t_i(X) \right) = -\frac{\partial}{\partial \theta_j} \log c(\boldsymbol{\theta}); \tag{3.4.4}\] \[\mathrm{Var}\left( \sum_{i=1}^k \frac{\partial w_i(\boldsymbol{\theta})}{\partial \theta_j} t_i(X) \right) = -\frac{\partial^2}{\partial \theta_j^2} \log c(\boldsymbol{\theta}) - \mathrm{E}\left( \sum_{i=1}^k \frac{\partial^2 w_i(\boldsymbol{\theta})}{\partial \theta_j^2} t_i(X) \right). \tag{3.4.5}\]

The advantage of these identities is that they replace integration or summation by differentiation, which is often more straightforward.

Why (3.4.4) holds (one parameter, $k = 1$, continuous case; the full proof is Exercise 3.31). Start from $\int h(x) c(\theta) e^{w(\theta) t(x)}\, dx = 1$ and differentiate in $\theta$. Moving $\frac{d}{d\theta}$ inside the integral (§2.4 tells us when this is allowed),

\[\int h(x) \Big[ c'(\theta) + c(\theta) w'(\theta) t(x) \Big] e^{w(\theta) t(x)}\, dx = 0.\]

Divide by $c(\theta)$ and recognize each piece as an expectation: $\dfrac{c’(\theta)}{c(\theta)} + w’(\theta)\, \mathrm{E}\, t(X) = 0$, that is, $\mathrm{E}[w’(\theta) t(X)] = -\dfrac{d}{d\theta} \log c(\theta)$. Differentiating a second time gives (3.4.5).

Example 3.4.3 (Binomial mean and variance). From Example 3.4.1 we have

\[\frac{d}{dp} w_1(p) = \frac{d}{dp} \log \frac{p}{1 - p} = \frac{1}{p(1 - p)}, \qquad \frac{d}{dp} \log c(p) = \frac{d}{dp}\, n \log(1 - p) = \frac{-n}{1 - p},\]

and thus from (3.4.4)

\[\mathrm{E}\left( \frac{1}{p(1 - p)} X \right) = \frac{n}{1 - p},\]

and a bit of rearrangement yields $\mathrm{E}X = np$. The variance identity works in a similar manner. With $\frac{d^2}{dp^2} w_1(p) = -\frac{1 - 2p}{p^2(1 - p)^2}$ and $\frac{d^2}{dp^2} \log c(p) = \frac{-n}{(1 - p)^2}$, (3.4.5) gives

\[\begin{aligned} \frac{\mathrm{Var}\, X}{p^2 (1 - p)^2} &= \frac{n}{(1 - p)^2} + \frac{1 - 2p}{p^2(1 - p)^2}\, np \\ &= \frac{n\big[ p + (1 - 2p) \big]}{p (1 - p)^2} = \frac{n}{p(1 - p)}, \end{aligned}\]

so $\mathrm{Var}\, X = np(1 - p)$.

Example 3.4.4 (Normal exponential family). Let $f(x \mid \mu, \sigma^2)$ be the $\mathrm{n}(\mu, \sigma^2)$ family of pdfs, where $\boldsymbol{\theta} = (\mu, \sigma)$, $-\infty < \mu < \infty$, $\sigma > 0$. Then

\[\begin{aligned} f(x \mid \mu, \sigma^2) &= \frac{1}{\sqrt{2\pi}\, \sigma} \exp\left( -\frac{(x - \mu)^2}{2\sigma^2} \right) \\ &= \frac{1}{\sqrt{2\pi}\, \sigma} \exp\left( -\frac{\mu^2}{2\sigma^2} \right) \exp\left( -\frac{x^2}{2\sigma^2} + \frac{\mu x}{\sigma^2} \right). \end{aligned} \tag{3.4.6}\]

Define

\[h(x) = 1, \quad c(\mu, \sigma) = \frac{1}{\sqrt{2\pi}\, \sigma} \exp\left( \frac{-\mu^2}{2\sigma^2} \right), \quad w_1(\mu, \sigma) = \frac{1}{\sigma^2}, \quad w_2(\mu, \sigma) = \frac{\mu}{\sigma^2}, \quad t_1(x) = -\frac{x^2}{2}, \quad t_2(x) = x.\]

Then $f(x \mid \mu, \sigma^2) = h(x) c(\mu, \sigma) \exp[w_1(\mu, \sigma) t_1(x) + w_2(\mu, \sigma) t_2(x)]$, which is the form (3.4.1) with $k = 2$. Note again that the parameter functions are defined only over the range of the parameter.

The support cannot depend on $\boldsymbol{\theta}$. In general, the set of $x$ values for which $f(x \mid \boldsymbol{\theta}) > 0$ cannot depend on $\boldsymbol{\theta}$ in an exponential family. The entire definition of the pdf or pmf must be incorporated into the form (3.4.1). This is most easily accomplished by writing the range of $x$ with an indicator function.

Definition 3.4.5. The indicator function of a set $A$, most often denoted by $I_A(x)$, is the function

\[I_A(x) = \begin{cases} 1 & x \in A \\ 0 & x \notin A. \end{cases}\]

An alternative notation is $I(x \in A)$.

  • Thus, the normal pdf of Example 3.4.4 would be written $f(x \mid \mu, \sigma^2) = h(x) c(\mu, \sigma) \exp[w_1 t_1(x) + w_2 t_2(x)]\, I_{(-\infty, \infty)}(x)$. Since the indicator is a function of $x$ only, it can be absorbed into $h(x)$.
  • Since $\exp(\cdot) > 0$, for any $\boldsymbol{\theta}$ with $c(\boldsymbol{\theta}) > 0$ we have $\lbrace x : f(x \mid \boldsymbol{\theta}) > 0 \rbrace = \lbrace x : h(x) > 0 \rbrace$, which does not depend on $\boldsymbol{\theta}$.
  • A non-example. The pdfs $f(x \mid \theta) = \theta^{-1} \exp(1 - (x/\theta))$, $0 < \theta < x < \infty$, do not form an exponential family, even though $\theta^{-1}\exp(1 - x/\theta) = h(x) c(\theta) \exp(w(\theta) t(x))$ with $h(x) = e^1$, $c(\theta) = w(\theta) = \theta^{-1}$, and $t(x) = -x$. Writing the pdf with an indicator makes the problem clear:

    \[f(x \mid \theta) = \theta^{-1} \exp\left( 1 - \frac{x}{\theta} \right) I_{[\theta, \infty)}(x).\]

    The indicator is not a function of $x$ alone, not a function of $\theta$ alone, and cannot be written as an exponential. For the same reason, uniform(0, $\theta$) is not an exponential family.

6. Natural parameters and curved families

An exponential family is sometimes reparameterized as

\[f(x \mid \boldsymbol{\eta}) = h(x)\, c^{\ast}(\boldsymbol{\eta}) \exp\left( \sum_{i=1}^k \eta_i t_i(x) \right). \tag{3.4.7}\]

Here $h(x)$ and $t_i(x)$ are the same as in (3.4.1). The set

\[\mathcal{H} = \left\lbrace \boldsymbol{\eta} = (\eta_1, \dots, \eta_k) : \int_{-\infty}^{\infty} h(x) \exp\left( \sum_{i=1}^k \eta_i t_i(x) \right) dx < \infty \right\rbrace\]

is called the natural parameter space for the family. (The integral is replaced by a sum over the values of $x$ for which $h(x) > 0$ if $X$ is discrete.)

  • For $\boldsymbol{\eta} \in \mathcal{H}$, we must have $c^{\ast}(\boldsymbol{\eta}) = \left[ \int h(x) \exp\left( \sum_i \eta_i t_i(x) \right) dx \right]^{-1}$ to ensure that the pdf integrates to 1.
  • Since the original $f(x \mid \boldsymbol{\theta})$ in (3.4.1) is a pdf or pmf, the set $\lbrace \boldsymbol{\eta} = (w_1(\boldsymbol{\theta}), \dots, w_k(\boldsymbol{\theta})) : \boldsymbol{\theta} \in \Theta \rbrace$ must be a subset of the natural parameter space. But there may be other values of $\boldsymbol{\eta} \in \mathcal{H}$ also.
  • The natural parameterization and the natural parameter space have many useful mathematical properties. For example, $\mathcal{H}$ is convex.
  • In the natural parameterization, Theorem 3.4.2 simplifies to $\mathrm{E}\, t_j(X) = -\frac{\partial}{\partial \eta_j} \log c^{\ast}(\boldsymbol{\eta})$ and $\mathrm{Var}\, t_j(X) = -\frac{\partial^2}{\partial \eta_j^2} \log c^{\ast}(\boldsymbol{\eta})$ (Exercise 3.32).

Example 3.4.6 (Continuation of Example 3.4.4). To determine the natural parameter space for the normal family of distributions, replace $w_i(\mu, \sigma)$ with $\eta_i$ in (3.4.6) to obtain

\[f(x \mid \eta_1, \eta_2) = \frac{\sqrt{\eta_1}}{\sqrt{2\pi}} \exp\left( -\frac{\eta_2^2}{2\eta_1} \right) \exp\left( -\frac{\eta_1 x^2}{2} + \eta_2 x \right). \tag{3.4.8}\]

The integral will be finite if and only if the coefficient on $x^2$ is negative. This means $\eta_1$ must be positive. If $\eta_1 > 0$, the integral will be finite regardless of the value of $\eta_2$. Thus the natural parameter space is $\lbrace (\eta_1, \eta_2) : \eta_1 > 0, -\infty < \eta_2 < \infty \rbrace$. Identifying (3.4.8) with (3.4.6), we see that $\eta_2 = \mu/\sigma^2$ and $\eta_1 = 1/\sigma^2$. Although natural parameters provide a convenient mathematical formulation, they sometimes lack simple interpretations like the mean and variance.

Curved exponential families. In the representation (3.4.1) it is often the case that the dimension of the vector $\boldsymbol{\theta}$ is equal to $k$, the number of terms in the sum in the exponent. This need not be so.

Definition 3.4.7. A curved exponential family is a family of densities of the form (3.4.1) for which the dimension of the vector $\boldsymbol{\theta}$ is equal to $d < k$. If $d = k$, the family is a full exponential family.

Example 3.4.8 (A curved exponential family). The normal family of Example 3.4.4 is a full exponential family. However, if we assume that $\sigma^2 = \mu^2$, the family becomes curved. We then have

\[\begin{aligned} f(x \mid \mu) &= \frac{1}{\sqrt{2\pi\mu^2}} \exp\left( -\frac{(x - \mu)^2}{2\mu^2} \right) \\ &= \frac{1}{\sqrt{2\pi\mu^2}} \exp\left( -\frac{1}{2} \right) \exp\left( -\frac{x^2}{2\mu^2} + \frac{x}{\mu} \right). \end{aligned} \tag{3.4.9}\]

For the normal family the full exponential family would have parameter space $(\mu, \sigma^2) = \mathbb{R} \times (0, \infty)$, while the parameter space of the curved family $(\mu, \sigma^2) = (\mu, \mu^2)$ is a parabola: one parameter, but still $k = 2$ terms in the exponent.

Example 3.4.9 (Normal approximations). In Chapter 5 we will see that if $X_1, \dots, X_n$ is a sample from a Poisson($\lambda$) population, then the distribution of $\bar{X} = \sum_i X_i / n$ is approximately $\mathrm{n}(\lambda, \lambda/n)$, a curved exponential family. Similarly, the normal approximation to the binomial (§1) gives $\bar{X} \sim \mathrm{n}(p, p(1 - p)/n)$ approximately, for iid Bernoulli($p$) $X_i$. Most such Central Limit Theorem approximations result in a curved normal family.

  • Theorem 3.4.2 applies to curved exponential families as well.
  • Why statisticians care. If a large sample comes from a pdf or pmf of the form (3.4.1), then the $k$ numbers $\sum_j t_1(x_j), \dots, \sum_j t_k(x_j)$ summarize all the information about $\boldsymbol{\theta}$ in the data. This “data reduction” property (sufficient statistics) is treated in Chapter 6 (Theorem 6.2.10).

Check your understanding.

  1. Show that the Poisson($\lambda$) family, $\lambda > 0$, is an exponential family, and use Theorem 3.4.2 to find $\mathrm{E}X$ and $\mathrm{Var}\, X$.

    Show answer

    $f(x \mid \lambda) = \dfrac{e^{-\lambda} \lambda^x}{x!} = \dfrac{1}{x!} I_{\lbrace 0, 1, \dots \rbrace}(x) \cdot e^{-\lambda} \cdot \exp(x \log \lambda)$. So $h(x) = \frac{1}{x!} I_{\lbrace 0, 1, \dots \rbrace}(x)$, $c(\lambda) = e^{-\lambda}$, $w(\lambda) = \log \lambda$, and $t(x) = x$.

    With $w’(\lambda) = 1/\lambda$ and $\frac{d}{d\lambda} \log c(\lambda) = -1$, (3.4.4) gives $\mathrm{E}(X/\lambda) = 1$, so $\mathrm{E}X = \lambda$. With $w’’(\lambda) = -1/\lambda^2$ and $\frac{d^2}{d\lambda^2} \log c(\lambda) = 0$, (3.4.5) gives

    \[\mathrm{Var}\left( \frac{X}{\lambda} \right) = 0 + \mathrm{E}\left( \frac{X}{\lambda^2} \right) = \frac{1}{\lambda},\]

    so $\mathrm{Var}\, X = \lambda$.

  2. What is the natural parameter space of the Poisson family?

    Show answer

    With $\eta = \log \lambda$, the condition is $\sum_{x=0}^{\infty} \frac{1}{x!} e^{\eta x} = \exp(e^{\eta}) < \infty$, which holds for every real $\eta$. So $\mathcal{H} = (-\infty, \infty)$, which is exactly $\lbrace \log \lambda : \lambda > 0 \rbrace$, and $c^{\ast}(\eta) = \exp(-e^{\eta})$.

  3. Is the gamma($\alpha$, $\beta$) family, with both parameters unknown, a full exponential family? Identify $h$, $c$, $w_i$, and $t_i$.

    Show answer

    Yes. For $x > 0$,

    \[f(x \mid \alpha, \beta) = \frac{1}{\Gamma(\alpha)\beta^{\alpha}} x^{\alpha - 1} e^{-x/\beta} = \underbrace{\frac{1}{x} I_{(0, \infty)}(x)}_{h(x)} \cdot \underbrace{\frac{1}{\Gamma(\alpha)\beta^{\alpha}}}_{c(\alpha, \beta)} \cdot \exp\Big( \underbrace{\alpha}_{w_1} \underbrace{\log x}_{t_1} + \underbrace{(-1/\beta)}_{w_2}\, \underbrace{x}_{t_2} \Big).\]

    The parameter $(\alpha, \beta)$ has dimension $d = 2 = k$, so the family is full. The support $(0, \infty)$ does not depend on the parameters.


Location and Scale Families

Way of thinking. Simplify $X = \sigma Z + \mu$ to a “standard” $Z$.

7. Location, scale, and location–scale families

In this section we discuss three techniques for constructing families of distributions: location families, scale families, and location–scale families. Each is constructed by specifying a single pdf, say $f(x)$, called the standard pdf for the family. Then all other pdfs in the family are generated by transforming the standard pdf in a prescribed way. We start with a simple theorem about pdfs.

Theorem 3.5.1. Let $f(x)$ be any pdf and let $\mu$ and $\sigma > 0$ be any given constants. Then the function

\[g(x \mid \mu, \sigma) = \frac{1}{\sigma} f\left( \frac{x - \mu}{\sigma} \right)\]

is a pdf.

Proof. We must check that $(1/\sigma) f((x - \mu)/\sigma)$, as a function of $x$, is nonnegative and integrates to 1 for every $\mu$ and $\sigma$. Since $f(x) \ge 0$ for all $x$, $(1/\sigma) f((x - \mu)/\sigma) \ge 0$ for all $x$, $\mu$, and $\sigma$. Next,

\[\int_{-\infty}^{\infty} \frac{1}{\sigma} f\left( \frac{x - \mu}{\sigma} \right) dx = \int_{-\infty}^{\infty} f(y)\, dy = 1, \qquad \left( \text{substitute } y = \frac{x - \mu}{\sigma} \right)\]

since $f(y)$ is a pdf. $\square$

Definition 3.5.2. Let $f(x)$ be any pdf. Then the family of pdfs $f(x - \mu)$, indexed by the parameter $\mu$, $-\infty < \mu < \infty$, is called the location family with standard pdf $f(x)$, and $\mu$ is called the location parameter for the family.

  • The effect of $\mu$. At $x = \mu + a$, $f(x - \mu) = f(a)$. So $\mu$ simply shifts the graph of $f(x)$ to the right by $\mu$, without changing its shape: the point that was above $x = 0$ for $f(x)$ is above $x = \mu$ for $f(x - \mu)$ (C&B Figure 3.5.1). Areas shift too:

    \[P(-1 \le X \le 2 \mid 0) = P(\mu - 1 \le X \le \mu + 2 \mid \mu),\]

    where $X$ has pdf $f(x - 0) = f(x)$ on the left and pdf $f(x - \mu)$ on the right.

  • Examples. With $\sigma > 0$ known, the $\mathrm{n}(\mu, \sigma^2)$ pdfs form the location family with standard pdf $f(x) = \frac{1}{\sqrt{2\pi}\sigma} e^{-x^2/(2\sigma^2)}$. The Cauchy and double exponential families with $\sigma$ fixed are also location families.
  • When is a location family a good model? If $X$ has pdf $f(x - \mu)$, then $X = Z + \mu$, where $Z$ has pdf $f(z)$ (Theorem 3.5.6 below, with $\sigma = 1$).
    • Measurement error. We measure a physical constant $\mu$ (say, the temperature of a solution) with an instrument whose error $Z$ has a known pdf $f(z)$. The reading is $X = \mu + Z$, with pdf $f(x - \mu)$.
    • Treatment effect. Reaction times $Z$ of drivers have a known pdf $f(z)$. If a treatment (three glasses of beer) changes everyone’s reaction time by the same unknown amount $\mu$, the treated reaction time is $X = Z + \mu$. (This model is too simple: the effect of alcohol depends on body weight. But it is a starting point.)
  • If the set of $x$ for which $f(x) > 0$ is not the whole real line, then the set of $x$ for which $f(x - \mu) > 0$ depends on $\mu$.

Example 3.5.3 (Exponential location family). Let $f(x) = e^{-x}$, $x \ge 0$, and $f(x) = 0$, $x < 0$. To form a location family we replace $x$ with $x - \mu$ to obtain

\[f(x \mid \mu) = \begin{cases} e^{-(x - \mu)} & x - \mu \ge 0 \\ 0 & x - \mu < 0 \end{cases} = \begin{cases} e^{-(x - \mu)} & x \ge \mu \\ 0 & x < \mu. \end{cases}\]

The graph of $f(x \mid \mu)$ is the exponential pdf shifted to start at $\mu$ rather than at 0 (C&B Figure 3.5.2). If $X$ measures time, then $\mu$ might be restricted to be nonnegative so that $X$ is positive with probability 1 for every $\mu$. In this type of model, where $\mu$ denotes a bound on the range of $X$, $\mu$ is sometimes called a threshold parameter. Since its support $[\mu, \infty)$ depends on $\mu$, this family is not an exponential family (§5), even though each member is an exponential pdf.

Definition 3.5.4. Let $f(x)$ be any pdf. Then for any $\sigma > 0$, the family of pdfs $(1/\sigma) f(x/\sigma)$, indexed by the parameter $\sigma$, is called the scale family with standard pdf $f(x)$, and $\sigma$ is called the scale parameter of the family.

  • The effect of $\sigma$ is either to stretch ($\sigma > 1$) or to contract ($\sigma < 1$) the graph of $f(x)$ while still maintaining the same basic shape (C&B Figure 3.5.3). The factor $1/\sigma$ in front keeps the total area at 1: a wider pdf must be lower.
  • Most often when scale parameters are used, $f(x)$ is either symmetric about 0 or positive only for $x > 0$. In these cases the stretching is either symmetric about 0 or only in the positive direction.
  • Examples. The gamma family if $\alpha$ is a fixed value and $\beta$ is the scale parameter; the normal family if $\mu = 0$ and $\sigma$ is the scale parameter; the exponential family; and the double exponential family if $\mu = 0$ and $\sigma$ is the scale parameter. In each case the standard pdf is the pdf obtained by setting the scale parameter equal to 1.

Definition 3.5.5. Let $f(x)$ be any pdf. Then for any $\mu$, $-\infty < \mu < \infty$, and any $\sigma > 0$, the family of pdfs $(1/\sigma) f((x - \mu)/\sigma)$, indexed by the parameter $(\mu, \sigma)$, is called the location–scale family with standard pdf $f(x)$; $\mu$ is called the location parameter and $\sigma$ is called the scale parameter.

  • The effect of introducing both parameters is to stretch ($\sigma > 1$) or contract ($\sigma < 1$) the graph with the scale parameter and then shift the graph so that the point that was above 0 is now above $\mu$ (C&B Figure 3.5.4).
  • The normal and double exponential families are location–scale families. So is the Cauchy family: with $\mu$ and $\sigma$, its pdf is $f(x \mid \mu, \sigma) = \dfrac{1}{\sigma\pi \left( 1 + \left( \frac{x - \mu}{\sigma} \right)^2 \right)}$ (Exercise 3.39).

The next theorem connects the transformation of the pdf $f$ to the transformation of a random variable $Z$ with pdf $f$. Setting $\sigma = 1$ gives a result for location families, and setting $\mu = 0$ gives a result for scale families.

Theorem 3.5.6. Let $f(\cdot)$ be any pdf. Let $\mu$ be any real number, and let $\sigma$ be any positive real number. Then $X$ is a random variable with pdf $(1/\sigma) f((x - \mu)/\sigma)$ if and only if there exists a random variable $Z$ with pdf $f(z)$ and $X = \sigma Z + \mu$.

Proof. To prove the “if” part, define $g(z) = \sigma z + \mu$. Then $X = g(Z)$, $g$ is a monotone function, $g^{-1}(x) = (x - \mu)/\sigma$, and $\lvert (d/dx) g^{-1}(x) \rvert = 1/\sigma$. Thus by Theorem 2.1.5, the pdf of $X$ is

\[f_X(x) = f_Z\big( g^{-1}(x) \big) \left\lvert \frac{d}{dx} g^{-1}(x) \right\rvert = f\left( \frac{x - \mu}{\sigma} \right) \frac{1}{\sigma}.\]

To prove the “only if” part, define $g(x) = (x - \mu)/\sigma$ and let $Z = g(X)$. Theorem 2.1.5 again applies: $g^{-1}(z) = \sigma z + \mu$, $\lvert (d/dz) g^{-1}(z) \rvert = \sigma$, and the pdf of $Z$ is

\[f_Z(z) = f_X\big( g^{-1}(z) \big) \left\lvert \frac{d}{dz} g^{-1}(z) \right\rvert = \frac{1}{\sigma} f\left( \frac{(\sigma z + \mu) - \mu}{\sigma} \right) \sigma = f(z).\]

Also, $\sigma Z + \mu = \sigma g(X) + \mu = \sigma \left( \frac{X - \mu}{\sigma} \right) + \mu = X$. $\square$

  • An important fact to extract from Theorem 3.5.6 is that the random variable $Z = (X - \mu)/\sigma$ has pdf $f_Z(z) = \frac{1}{1} f\left( \frac{z - 0}{1} \right) = f(z)$. That is, the distribution of $Z$ is the member of the location–scale family corresponding to $\mu = 0$, $\sigma = 1$. We proved this for the normal family in §1 (“Standardizing”).

Theorem 3.5.7. Let $Z$ be a random variable with pdf $f(z)$. Suppose $\mathrm{E}Z$ and $\mathrm{Var}\, Z$ exist. If $X$ is a random variable with pdf $(1/\sigma) f((x - \mu)/\sigma)$, then

\[\mathrm{E}X = \sigma \mathrm{E}Z + \mu \quad \text{and} \quad \mathrm{Var}\, X = \sigma^2 \mathrm{Var}\, Z.\]

In particular, if $\mathrm{E}Z = 0$ and $\mathrm{Var}\, Z = 1$, then $\mathrm{E}X = \mu$ and $\mathrm{Var}\, X = \sigma^2$.

Proof. By Theorem 3.5.6, there is a random variable $Z^{\ast}$ with pdf $f(z)$ and $X = \sigma Z^{\ast} + \mu$. So $\mathrm{E}X = \sigma \mathrm{E}Z^{\ast} + \mu = \sigma \mathrm{E}Z + \mu$ and $\mathrm{Var}\, X = \sigma^2 \mathrm{Var}\, Z^{\ast} = \sigma^2 \mathrm{Var}\, Z$. $\square$

  • For any location–scale family with a finite mean and variance, the standard pdf $f(z)$ can be chosen so that $\mathrm{E}Z = 0$ and $\mathrm{Var}\, Z = 1$ (Exercise 3.40). Then $\mu$ and $\sigma^2$ are the mean and variance of $X$. This is the case for the usual definition of the normal family. It is not the case for the double exponential family as defined in (3.3.22): there $\mathrm{Var}\, Z = 2$, so $\mathrm{Var}\, X = 2\sigma^2$.
  • For the Cauchy family the mean and variance do not exist, so $\mu$ and $\sigma$ cannot be the mean and standard deviation. They are still meaningful: $\mu$ is the median, and $\mu \pm \sigma$ are the quartiles (Exercise 3.39).
  • Probabilities. Probabilities for any member of a location–scale family may be computed in terms of the standard variable $Z$, because

    \[P(X \le x) = P\left( \frac{X - \mu}{\sigma} \le \frac{x - \mu}{\sigma} \right) = P\left( Z \le \frac{x - \mu}{\sigma} \right).\]

    Thus, if $P(Z \le z)$ is tabulated or easily calculable for the standard variable $Z$, then probabilities for $X$ may be obtained. Calculations of normal probabilities using the standard normal table are examples of this.

Check your understanding.

  1. Show that for fixed $\alpha$ the gamma($\alpha$, $\beta$) family is a scale family, and identify the standard pdf.

    Show answer

    Take the standard pdf $f(x) = f(x \mid \alpha, 1) = \frac{1}{\Gamma(\alpha)} x^{\alpha - 1} e^{-x}$, $x > 0$. Then

    \[\frac{1}{\beta} f\left( \frac{x}{\beta} \right) = \frac{1}{\beta} \cdot \frac{1}{\Gamma(\alpha)} \left( \frac{x}{\beta} \right)^{\alpha - 1} e^{-x/\beta} = \frac{1}{\Gamma(\alpha) \beta^{\alpha}} x^{\alpha - 1} e^{-x/\beta} = f(x \mid \alpha, \beta),\]

    which is Definition 3.5.4 with $\sigma = \beta$. Equivalently, $X = \beta T$ with $T \sim$ gamma($\alpha$, 1), which is how we built the gamma family last week.

  2. Let $X$ have the double exponential pdf (3.3.22). Use Theorem 3.5.7 to find $\mathrm{E}X$ and $\mathrm{Var}\, X$.

    Show answer

    The standard pdf is $f(z) = \frac{1}{2} e^{-\lvert z \rvert}$. By symmetry $\mathrm{E}Z = 0$, and

    \[\mathrm{E}Z^2 = 2 \int_0^{\infty} \frac{1}{2} z^2 e^{-z}\, dz = \Gamma(3) = 2,\]

    so $\mathrm{Var}\, Z = 2$. By Theorem 3.5.7, $\mathrm{E}X = \sigma \cdot 0 + \mu = \mu$ and $\mathrm{Var}\, X = 2\sigma^2$. This avoids the split integrals (3.3.23).

  3. Let $X$ have the Cauchy pdf with location $\mu$ and scale $\sigma$. Find $P(X \le \mu + \sigma)$.

    Show answer

    Standardize: $Z = (X - \mu)/\sigma \sim$ Cauchy(0), with cdf $F_Z(z) = \frac{1}{2} + \frac{1}{\pi} \arctan z$. So

    \[P(X \le \mu + \sigma) = P(Z \le 1) = \frac{1}{2} + \frac{1}{\pi} \cdot \frac{\pi}{4} = \frac{3}{4}.\]

    By symmetry $P(X \le \mu - \sigma) = \frac{1}{4}$, so $\mu \pm \sigma$ are the quartiles (Exercise 3.39(b)).


Summary of Week 8

Continuous families, continued (§3.3):

Distribution Mean Variance Mgf
$\mathrm{n}(\mu, \sigma^2)$ $\mu$ $\sigma^2$ $e^{\mu t + \sigma^2 t^2/2}$
beta$(\alpha, \beta)$ $\dfrac{\alpha}{\alpha + \beta}$ $\dfrac{\alpha\beta}{(\alpha + \beta)^2 (\alpha + \beta + 1)}$ (no simple form)
Cauchy$(\theta)$ does not exist does not exist does not exist
lognormal$(\mu, \sigma^2)$ $e^{\mu + \sigma^2/2}$ $e^{2(\mu + \sigma^2)} - e^{2\mu + \sigma^2}$ does not exist
double exponential$(\mu, \sigma)$ $\mu$ $2\sigma^2$ $\dfrac{e^{\mu t}}{1 - (\sigma t)^2}$, $\lvert t \rvert < \dfrac{1}{\sigma}$
  • Normal: standardize with $Z = (X - \mu)/\sigma$; $\int e^{-z^2/2} dz = \sqrt{2\pi}$ by polar coordinates; $\Gamma(\frac{1}{2}) = \sqrt{\pi}$. Binomial $\approx \mathrm{n}(np, np(1 - p))$ for $\min(np, n(1 - p)) \ge 5$, with the continuity correction $\pm\frac{1}{2}$.
  • Beta: a flexible family on $(0, 1)$ for proportions; $B(\alpha, \beta) = \Gamma(\alpha)\Gamma(\beta)/\Gamma(\alpha + \beta)$; $\mathrm{E}X^n = B(\alpha + n, \beta)/B(\alpha, \beta)$ by the kernel technique; uniform(0, 1) = beta(1, 1).
  • Cauchy: bell-shaped, but with $1/t$ tails, so no moments exist; $\theta$ is the median.

Exponential families (§3.4):

  • Form (3.4.1): $f(x \mid \boldsymbol{\theta}) = h(x) c(\boldsymbol{\theta}) \exp\left( \sum_{i=1}^k w_i(\boldsymbol{\theta}) t_i(x) \right)$. Includes the normal, gamma, beta, binomial, Poisson, and negative binomial ($r$ known).
  • The support $\lbrace x : h(x) > 0 \rbrace$ cannot depend on $\boldsymbol{\theta}$; use indicator functions to check. Uniform(0, $\theta$) and the exponential location family are not exponential families.
  • Theorem 3.4.2: moments of $t_i(X)$ from derivatives of $\log c(\boldsymbol{\theta})$.
  • Natural parameters $\eta_i = w_i(\boldsymbol{\theta})$; natural parameter space $\mathcal{H}$ (convex). Curved family: $\dim \boldsymbol{\theta} = d < k$.

Location and scale families (§3.5):

Family pdf Representation Examples
location $f(x - \mu)$ $X = Z + \mu$ $\mathrm{n}(\mu, \sigma_0^2)$, exponential location (threshold)
scale $\frac{1}{\sigma} f(x/\sigma)$ $X = \sigma Z$ gamma with $\alpha$ fixed, exponential, $\mathrm{n}(0, \sigma^2)$
location–scale $\frac{1}{\sigma} f\left( \frac{x - \mu}{\sigma} \right)$ $X = \sigma Z + \mu$ normal, double exponential, Cauchy
  • Theorem 3.5.6: $X$ has pdf $\frac{1}{\sigma} f((x - \mu)/\sigma)$ iff $X = \sigma Z + \mu$ with $Z \sim f$. Theorem 3.5.7: $\mathrm{E}X = \sigma \mathrm{E}Z + \mu$, $\mathrm{Var}\, X = \sigma^2 \mathrm{Var}\, Z$.

Practice Problems

From C&B §3.7:

  • Continuous families: 3.20, 3.21, 3.22(d, e), 3.23, 3.27.
  • Exponential families: 3.28(a, b, d), 3.29(a, d), 3.30(a), 3.31(a), 3.33(a).
  • Location and scale families: 3.37, 3.38, 3.39, 3.40.

Next week (Nov. 24): inequalities and identities (§3.6), and Chapter 4, Multiple Random Variables, starting with joint and marginal distributions (§4.1). See the Week 9 notes.