Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Linear transformations are both simple and ubiquitous: every time you change units of measurement, for example to standard units, you are performing a linear transformation.

16.1.1Linear Transformation: Exponential Density

Let TT have the exponential (λ)(\lambda) distribution and let T1=λTT_1 = \lambda T. Then T1T_1 is a linear transformation of TT. Therefore

E(T1)=λE(T)=1   and   SD(T1)=λSD(T)=1E(T_1) = \lambda E(T) = 1 ~~~ \text{and} ~~~ SD(T_1) = \lambda SD(T) = 1

The parameter λ\lambda has disappeared in these results. Let’s see how that follows from the distribution of T1T_1. The cdf of T1T_1 is

FT1(t)=P(T1t)=P(Tt/λ)=1eλ(t/λ)=1etF_{T_1}(t) = P(T_1 \le t) = P(T \le t/\lambda) = 1 - e^{-\lambda (t/\lambda)} = 1 - e^{-t}

That’s the cdf of the exponential (1)(1) distribution, consistent with the expectation and SD we found above.

To summarize, if TT has the exponential (λ)(\lambda) distribution then the distribution of T1=λTT_1 = \lambda T is exponential (1)(1).

You can think of the exponential (1)(1) distribution as the fundamental member of the family of exponential distributions. All others in the family can be found by changing the scale of measurement, that is, by multiplying by a constant.

If T1T_1 has the exponential (1)(1) distribution, then T=1λT1T = \frac{1}{\lambda}T_1 has the exponential (λ)(\lambda) distribution. The factor 1/λ1/\lambda is called the scale parameter.

Here are graphs of the densities of T1T_1 and T=12T1T = \frac{1}{2}T_1. By the paragraph above, TT has the exponential (2)(2) distribution.

<Figure size 432x288 with 1 Axes>

The formulas for the two densities are

fT1(s)=es              fT(t)=2e2tf_{T_1} (s) = e^{-s} ~~~~~~~~~~~~~~ f_T(t) = 2e^{-2t}

Let’s try to understand the relation between these two densities in a way that will help us generalize what we are seeing in this example.

The relation between the two random variables is T=12T1T = \frac{1}{2}T_1.

  • For any tt, the chance that TT is near tt is the same as the chance that T1T_1 is near s=2ts = 2t. This explains the factor e2te^{-2t} in the density of TT.

  • If we think of T1T_1 as a point on the horizontal axis, then to create TT you have to divide T1T_1 by 2. So the transformation consists of halving all distances on the horizontal axis. The total area under the density of TT must equal 1, so we have to compensate by doubling all distances on the vertical axis. This explains the factor 2 in the density of TT.

🎥 See More
Loading...

16.1.2Linear Change of Variable Formula for Densities

We use the same idea to find the density of a linear transformation of a random variable.

Let XX be a random variable with density fXf_X, and let Y=aX+bY = aX + b for constants a0a \ne 0 and bb. Let fYf_Y be the density of YY. Then

fY(y) = fX(yba)1af_Y(y) ~ = ~ f_X\big( \frac{y-b}{a}\big) \frac{1}{\lvert a \rvert}

Let’s take this formula in two pieces, as in the exponential example.

  • For YY to be yy, XX has to be (yb)/a(y-b)/a.

  • The linear function y=ax+by = ax+b involves multiplying distances along the horizontal axis by a\lvert a \rvert; the sign of aa doesn’t affect distances. To get a density, we have to compensate by dividing all vertical distances by a\lvert a \rvert.

This is a good way to understand the formula, and will help you understand the corresponding formula for non-linear transformations.

For a formal proof, start with the case a>0a > 0.

FY(y)=P(aX+by)=P(Xyba)=FX(yba)F_Y(y) = P(aX+b \le y) = P\big(X \le \frac{y-b}{a}\big) = F_X\big(\frac{y-b}{a}\big)

By the chain rule of differentiation,

fY(y)=fX(yba)1af_Y(y) = f_X\big(\frac{y-b}{a}\big) \cdot \frac{1}{a}

If a<0a < 0 then division by aa causes the direction of the inequality to switch:

FY(y)=P(aX+by)=P(Xyba)=1FX(yba)F_Y(y) = P(aX+b \le y) = P\big(X \ge \frac{y-b}{a}\big) = 1 - F_X\big(\frac{y-b}{a}\big)

Now the chain rule yields

fY(y) = fX(yba)1a = fX(yba)1af_Y(y) ~ = ~ -f_X\big(\frac{y-b}{a}\big) \cdot \frac{1}{a} ~ = ~ f_X\big(\frac{y-b}{a}\big) \cdot \frac{1}{\lvert a \rvert}

16.1.3The Normal Densities

Let ZZ have the standard normal density

ϕ(z) = 12πe12z2,   <z<\phi(z) ~ = ~ \frac{1}{\sqrt{2\pi}} e^{-\frac{1}{2}z^2}, ~~~ -\infty < z < \infty

Let X=σZ+μX = \sigma Z + \mu for constants μ\mu and σ\sigma with σ>0\sigma > 0. Then for any real number xx, the density of XX is

fX(x) = ϕ(xμσ)1σ= 12πσe12(xμσ)2\begin{align*} f_X(x) ~ &= ~ \phi\big( \frac{x-\mu}{\sigma} \big) \frac{1}{\sigma} \\ \\ &= ~ \frac{1}{\sqrt{2\pi}\sigma} e^{-\frac{1}{2} \big( \frac{x-\mu}{\sigma} \big)^2} \end{align*}

Thus every normal random variable is a linear transformation of a standard normal variable.

16.1.4The Uniform Densities, Revisited

Let the distribution of UU be uniform on (0,1)(0, 1) and for constants b>ab > a let V=(ba)U+aV = (b-a)U + a. In an earlier section we saw that VV has the uniform distribution on (a,b)(a, b). But let’s see what’s involved in confirming that result using our new formula.

First it is a good idea to be clear about the possible values of VV. Since the possible values of UU are in (0,1)(0, 1), the possible values of VV are in (a,b)(a, b).

At v(a,b)v \in (a, b), the density of VV is

fV(v) = fU(vaba)1ba = 11ba = 1baf_V(v) ~ = ~ f_U\big( \frac{v - a}{b-a} \big) \frac{1}{b-a} ~ = ~ 1 \cdot \frac{1}{b-a} ~ = ~ \frac{1}{b-a}

That’s the uniform density on (a,b)(a, b).