Multivariate normal distribution

From Wikipedia, the free encyclopedia
  (Redirected from Jointly Gaussian)
Jump to: navigation, search
"MVN" redirects here. For the airport with that IATA code, see Mount Vernon Airport.
Probability density function
MultivariateNormal.png
Many samples from a multivariate normal distribution, shown along with the 3-sigma ellipse, the two marginal distributions, and the two 1-d histograms.
Notation \mathcal{N}(\boldsymbol\mu,\,\boldsymbol\Sigma)
Parameters μRklocation
ΣRk×kcovariance (nonnegative-definite matrix)
Support xμ+span(Σ) ⊆ Rk
pdf (2\pi)^{-\frac{k}{2}}|\boldsymbol\Sigma|^{-\frac{1}{2}}\, e^{ -\frac{1}{2}(\mathbf{x}-\boldsymbol\mu)'\boldsymbol\Sigma^{-1}(\mathbf{x}-\boldsymbol\mu) },
exists only when Σ is positive-definite
CDF (no analytic expression)
Mean μ
Mode μ
Variance Σ
Entropy \frac{k}{2} (1 + \ln (2\pi)) + \frac{1}{2} \ln |\boldsymbol\Sigma |
MGF \exp\!\Big( \boldsymbol\mu'\mathbf{t} + \tfrac{1}{2} \mathbf{t}'\boldsymbol\Sigma \mathbf{t}\Big)
CF \exp\!\Big( i\boldsymbol\mu'\mathbf{t} - \tfrac{1}{2} \mathbf{t}'\boldsymbol\Sigma \mathbf{t}\Big)

In probability theory and statistics, the multivariate normal distribution or multivariate Gaussian distribution, is a generalization of the one-dimensional (univariate) normal distribution to higher dimensions. One possible definition is that a random vector is said to be k-variate normally distributed if every linear combination of its k components has a univariate normal distribution. However, its importance derives mainly from the multivariate central limit theorem. The multivariate normal distribution is often used to describe, at least approximately, any set of (possibly) correlated real-valued random variables each of which clusters around a mean value.

Notation and parametrization[edit]

The multivariate normal distribution of a k-dimensional random vector x = [X1, X2, …, Xk] can be written in the following notation:


    \mathbf{x}\ \sim\ \mathcal{N}(\boldsymbol\mu,\, \boldsymbol\Sigma),

or to make it explicitly known that X is k-dimensional,


    \mathbf{x}\ \sim\ \mathcal{N}_k(\boldsymbol\mu,\, \boldsymbol\Sigma).

with k-dimensional mean vector

 \boldsymbol\mu = [ \operatorname{E}[X_1], \operatorname{E}[X_2], \ldots, \operatorname{E}[X_k]]

and k \times k covariance matrix

 \boldsymbol\Sigma = [\operatorname{Cov}[X_i, X_j]], i=1,2,\ldots,k; j=1,2,\ldots,k

Definition[edit]

A random vector x = (X1, …, Xk)' is said to have the multivariate normal distribution if it satisfies the following equivalent conditions.[1]

  • Every linear combination of its components Y = a1X1 + … + akXk is normally distributed. That is, for any constant vector aRk, the random variable Y = a′x has a univariate normal distribution.
  • There exists a random -vector z, whose components are independent standard normal random variables, a k-vector μ, and a k×ℓ matrix A, such that x = Az + μ. Here is the rank of the covariance matrix Σ = AA′. Especially in the case of full rank, see the section below on Geometric interpretation.

    \varphi_\mathbf{x}(\mathbf{u}) = \exp\Big( i\mathbf{u}'\boldsymbol\mu - \tfrac{1}{2} \mathbf{u}'\boldsymbol\Sigma \mathbf{u} \Big).

The covariance matrix is allowed to be singular (in which case the corresponding distribution has no density). This case arises frequently in statistics; for example, in the distribution of the vector of residuals in the ordinary least squares regression. Note also that the Xi are in general not independent; they can be seen as the result of applying the matrix A to a collection of independent Gaussian variables z.

Properties[edit]

Density function[edit]

Bivariate normal joint density

Non-degenerate case[edit]

The multivariate normal distribution is said to be "non-degenerate" when the symmetric covariance matrix \boldsymbol\Sigma is positive definite. In this case the distribution has density[2]


f_{\mathbf x}(x_1,\ldots,x_k) =
\frac{1}{\sqrt{(2\pi)^k|\boldsymbol\Sigma|}}
\exp\left(-\frac{1}{2}({\mathbf x}-{\boldsymbol\mu})^T{\boldsymbol\Sigma}^{-1}({\mathbf x}-{\boldsymbol\mu})
\right),

where |\boldsymbol\Sigma| is the determinant of \boldsymbol\Sigma. Note how the equation above reduces to that of the univariate normal distribution if \boldsymbol\Sigma is a 1 \times 1 matrix (i.e. a real number).

Each iso-density locus—the locus of points in k-dimensional space each of which gives the same particular value of the density—is an ellipse or its higher-dimensional generalization; hence the multivariate normal is a special case of the elliptical distributions.

The descriptive statistic ({\mathbf x}-{\boldsymbol\mu})^T{\boldsymbol\Sigma}^{-1}({\mathbf x}-{\boldsymbol\mu}) in the non-degenerate multivariate normal distribution equation is known as the square of the Mahalanobis distance, which represents the distance of the test point {\mathbf x} from the mean {\boldsymbol\mu}. Note that in k = 1 case, along with the distribution reduces to univariate normal distribution, the statistic defined above also reduces to the square of the Euclidean distance.

Bivariate case

In the 2-dimensional nonsingular case (k = rank(Σ) = 2), the probability density function of a vector [X Y]′ is


    f(x,y) =
      \frac{1}{2 \pi  \sigma_x \sigma_y \sqrt{1-\rho^2}}
      \exp\left(
        -\frac{1}{2(1-\rho^2)}\left[
          \frac{(x-\mu_x)^2}{\sigma_x^2} +
          \frac{(y-\mu_y)^2}{\sigma_y^2} -
          \frac{2\rho(x-\mu_x)(y-\mu_y)}{\sigma_x \sigma_y}
        \right]
      \right),

where ρ is the correlation between X and Y and where  \sigma_x>0 and  \sigma_y>0 . In this case,


    \boldsymbol\mu = \begin{pmatrix} \mu_x \\ \mu_y \end{pmatrix}, \quad
    \boldsymbol\Sigma = \begin{pmatrix} \sigma_x^2 & \rho \sigma_x \sigma_y \\
                             \rho \sigma_x \sigma_y  & \sigma_y^2 \end{pmatrix}.

In the bivariate case, the first equivalent condition for multivariate normality can be made less restrictive: it is sufficient to verify that countably many distinct linear combinations of X and Y are normal in order to conclude that the vector [X Y]′ is bivariate normal.[3]

The bivariate iso-density loci plotted in the x,y-plane are ellipses. As the correlation parameter ρ increases, these loci appear to be squeezed to the following line :


    y\left( x \right) = {\mathop{\rm sgn}} \left( {{\rho }} \right)\frac{{{\sigma _y}}}{{{\sigma _x}}}\left( {x - {\mu _x}} \right) + {\mu _y}.

This is because the above expression - but without the rho being inside a signum function - is the best linear unbiased prediction of Y given a value of X.[4]

Degenerate case[edit]

If the covariance matrix \boldsymbol\Sigma is not full rank, then the multivariate normal distribution is degenerate and does not have a density. More precisely, it does not have a density with respect to k-dimensional Lebesgue measure (which is the usual measure assumed in calculus-level probability courses). Only random vectors whose distributions are absolutely continuous with respect to a measure are said to have densities (with respect to that measure). To talk about densities but avoid dealing with measure-theoretic complications it can be simpler to restrict attention to a subset of \text{rank}(\boldsymbol\Sigma) of the coordinates of \mathbf{x} such that the covariance matrix for this subset is positive definite; then the other coordinates may be thought of as an affine function of the selected coordinates.[citation needed]

To talk about densities meaningfully in the singular case, then, we must select a different base measure. Using the disintegration theorem we can define a restriction of Lebesgue measure to the \text{rank}(\boldsymbol\Sigma)-dimensional affine subspace of \mathbb{R}^k where the Gaussian distribution is supported, i.e. \{\boldsymbol\mu+\boldsymbol{\Sigma ^{1/2}}\mathbf{v} : \mathbf{v} \in \mathbb{R}^k \}. With respect to this measure the distribution has density:

f(\mathbf{x})=(\text{det}^*(2\pi\boldsymbol\Sigma))^{-\frac{1}{2}}\, e^{ -\frac{1}{2}(\mathbf{x}-\boldsymbol\mu)'\boldsymbol\Sigma^+(\mathbf{x}-\boldsymbol\mu) }

where \boldsymbol\Sigma^+ is the generalized inverse and det* is the pseudo-determinant.[5]

Higher moments[edit]

Main article: Isserlis’ theorem

The kth-order moments of x are defined by


\mu _{1,\dots,N}(\mathbf{x})\ \stackrel{\mathrm{def}}{=}\  \mu _{r_{1},\dots,r_{N}}(\mathbf{x})\ \stackrel{\mathrm{def}}{=}\  E\left[
\prod\limits_{j=1}^{N}x_j^{r_{j}}\right]

where r1 + r2 + ⋯ + rN = k.

The central k-order central moments are given as follows

(a) If k is odd, μ1, …, N(xμ) = 0.

(b) If k is even with k = 2λ, then


\mu _{1,\dots,2\lambda }(\mathbf{x}-\boldsymbol\mu )=\sum \left( \Sigma _{ij}\Sigma _{k\ell}\cdots\Sigma _{XZ}\right)

where the sum is taken over all allocations of the set \left\{ 1,\dots,2\lambda
\right\} into λ (unordered) pairs. That is, if you have a kth ( = 2λ = 6) central moment, you will be summing the products of λ = 3 covariances (the -μ notation has been dropped in the interests of parsimony):

\begin{align}
&{} E[x_1 x_2 x_3 x_4 x_5 x_6] \\
&{} = E[x_1 x_2 ]E[x_3 x_4 ]E[x_5 x_6 ] + E[x_1 x_2 ]E[x_3 x_5 ]E[x_4 x_6] + E[x_1 x_2 ]E[x_3 x_6 ]E[x_4 x_5] \\
&{} + E[x_1 x_3 ]E[x_2 x_4 ]E[x_5 x_6 ] + E[x_1 x_3 ]E[x_2 x_5 ]E[x_4 x_6 ] + E[x_1 x_3]E[x_2 x_6]E[x_4 x_5] \\
&+ E[x_1 x_4]E[x_2 x_3]E[x_5 x_6]+E[x_1 x_4]E[x_2 x_5]E[x_3 x_6]+E[x_1 x_4]E[x_2 x_6]E[x_3 x_5] \\
& + E[x_1 x_5]E[x_2 x_3]E[x_4 x_6]+E[x_1 x_5]E[x_2 x_4]E[x_3 x_6]+E[x_1 x_5]E[x_2 x_6]E[x_3 x_4] \\
& + E[x_1 x_6]E[x_2 x_3]E[x_4 x_5 ] + E[x_1 x_6]E[x_2 x_4 ]E[x_3 x_5] + E[x_1 x_6]E[x_2 x_5]E[x_3 x_4].
\end{align}

This yields (2\lambda -1)!/(2^{\lambda -1}(\lambda -1)!) terms in the sum (15 in the above case), each being the product of λ (in this case 3) covariances. For fourth order moments (four variables) there are three terms. For sixth-order moments there are 3 × 5 = 15 terms, and for eighth-order moments there are 3 × 5 × 7 = 105 terms.

The covariances are then determined by replacing the terms of the list \left[ 1,\dots,2\lambda \right] by the corresponding terms of the list consisting of r1 ones, then r2 twos, etc.. To illustrate this, examine the following 4th-order central moment case:

E\left[ x_i^4\right] = 3\Sigma _{ii}^2
E\left[ x_i^3 x_j\right] = 3\Sigma _{ii} \Sigma _{ij}
E\left[ x_i^2 x_j^2\right] = \Sigma _{ii}\Sigma_{jj}+2\left( \Sigma _{ij}\right) ^2
E\left[ x_i^2x_jx_k\right] = \Sigma _{ii}\Sigma _{jk}+2\Sigma _{ij}\Sigma _{ik}
E\left[ x_i x_j x_k x_n\right] = \Sigma _{ij}\Sigma _{kn}+\Sigma _{ik}\Sigma _{jn}+\Sigma _{in}\Sigma _{jk}.

where \Sigma_{ij} is the covariance of xi and xj. The idea with the above method is you first find the general case for a kth moment where you have k different x variables - E\left[ x_i x_j x_k x_n\right] and then you can simplify this accordingly. Say, you have E\left[ x_i^2 x_k x_n\right] then you simply let xi = xj and realise that \Sigma _{ii} = σi2.

Likelihood function[edit]

If the mean and variance matrix are unknown, a suitable log likelihood function for a single observation x would be:[citation needed]

\ln(L)= -\frac{1}{2} \ln (|\boldsymbol\Sigma|\,) -\frac{1}{2}(\mathbf{x}-\boldsymbol\mu)^{\rm T}\boldsymbol\Sigma^{-1}(\mathbf{x}-\boldsymbol\mu) - \frac{k}{2}\ln(2\pi)

where x is a vector of real numbers. The complex case, where z is a vector of complex numbers, would be

\ln(L) = -\frac{1}{2}\ln (|\boldsymbol\Sigma|\,) -\frac{1}{2}(\mathbf{z}-\boldsymbol\mu)^\dagger\boldsymbol\Sigma^{-1}(\mathbf{z}-\boldsymbol\mu) - \frac{k}{2}\ln(2\pi)

i.e. with the conjugate transpose (indicated by \dagger) replacing the normal transpose (indicated by {}^{\rm T}). A similar notation is used for multiple linear regression.[6]

Entropy[edit]

The differential entropy of the multivariate normal distribution is[7]


\begin{align}
h\left(f\right) & = -\int_{-\infty}^\infty \int_{-\infty}^\infty \cdots\int_{-\infty}^\infty f(\mathbf{x}) \ln f(\mathbf{x})\,d\mathbf{x},\\
& = \frac12 \ln\left|(2\pi e) \boldsymbol\Sigma \right|,\\
\end{align}

where the bars denote the matrix determinant.

Kullback–Leibler divergence[edit]

The Kullback–Leibler divergence from \mathcal{N}_0(\boldsymbol\mu_0, \boldsymbol\Sigma_0) to \mathcal{N}_1(\boldsymbol\mu_1, \boldsymbol\Sigma_1), for non-singular matrices Σ0 and Σ1, is:[8]


D_\text{KL}(\mathcal{N}_0 \| \mathcal{N}_1) = { 1 \over 2 } \left\{ \mathrm{tr} \left( \boldsymbol\Sigma_1^{-1} \boldsymbol\Sigma_0 \right) + \left( \boldsymbol\mu_1 - \boldsymbol\mu_0\right)^{\rm T} \boldsymbol\Sigma_1^{-1} ( \boldsymbol\mu_1 - \boldsymbol\mu_0 ) - K -\ln { |  \boldsymbol \Sigma_0 | \over | \boldsymbol\Sigma_1 | } \right\},

where K is the dimension of the vector space.

The logarithm must be taken to base e since the two terms following the logarithm are themselves base-e logarithms of expressions that are either factors of the density function or otherwise arise naturally. The equation therefore gives a result measured in nats. Dividing the entire expression above by loge 2 yields the divergence in bits.

Cumulative distribution function[edit]

The notion of cumulative distribution function (cdf) in dimension 1 can be extended in two ways to the multidimensional case. The first way is to define the cumulative distribution function F(r) as the probability that a sample falls inside the ellipsoid determined by its Mahalanobis distance r from the Gaussian, a direct generalization of the standard deviation .[9] In order to compute the values of this function, closed analytic formulae exist.[9]

Another way to extend the notion of cumulative distribution function is to define the cumulative distribution function (cdf) F(x0) of a random vector x as the probability that all components of x are less than or equal to the corresponding values in the vector x0. Though there is no closed form for F(x), there are a number of algorithms that estimate it numerically.[10]

Prediction Interval[edit]

The prediction interval for the multivariate normal distribution yields a region consisting of those vectors x satisfying

({\mathbf x}-{\boldsymbol\mu})^T{\boldsymbol\Sigma}^{-1}({\mathbf x}-{\boldsymbol\mu}) \leq \chi^2_k(p).

Here {\mathbf x} is a k-dimensional vector, {\boldsymbol\mu} is the known k-dimensional mean vector, \boldsymbol\Sigma is the known covariance matrix and \chi^2_k(p) is the quantile function for probability p of the chi-squared distribution with k degrees of freedom.[11]

When k = 2, the expression defines the interior of an ellipse and the chi-squared distribution simplifies to an exponential distribution with mean equal to two.

Joint normality[edit]

Normally distributed and independent[edit]

If X and Y are normally distributed and independent, this implies they are "jointly normally distributed", i.e., the pair (XY) must have multivariate normal distribution. However, a pair of jointly normally distributed variables need not be independent (would only be so if uncorrelated,  \rho = 0 ).

Two normally distributed random variables need not be jointly bivariate normal[edit]

The fact that two random variables X and Y both have a normal distribution does not imply that the pair (XY) has a joint normal distribution. A simple example is one in which X has a normal distribution with expected value 0 and variance 1, and Y = X if |X| > c and Y = −X if |X| < c, where c > 0. There are similar counterexamples for more than two random variables. In general, they sum to a mixture model.

Correlations and independence[edit]

In general, random variables may be uncorrelated but highly dependent. But if a random vector has a multivariate normal distribution then any two or more of its components that are uncorrelated are independent. This implies that any two or more of its components that are pairwise independent are independent.

But it is not true that two random variables that are (separately, marginally) normally distributed and uncorrelated are independent. Two random variables that are normally distributed may fail to be jointly normally distributed, i.e., the vector whose components they are may fail to have a multivariate normal distribution. In the preceding example, clearly X and Y are not independent, yet choosing c to be 1.54 makes them uncorrelated.

Conditional distributions[edit]

If μ and Σ are partitioned as follows


\boldsymbol\mu
=
\begin{bmatrix}
 \boldsymbol\mu_1 \\
 \boldsymbol\mu_2
\end{bmatrix}
\text{ with sizes }\begin{bmatrix} q \times 1 \\ (N-q) \times 1 \end{bmatrix}

\boldsymbol\Sigma
=
\begin{bmatrix}
 \boldsymbol\Sigma_{11} & \boldsymbol\Sigma_{12} \\
 \boldsymbol\Sigma_{21} & \boldsymbol\Sigma_{22}
\end{bmatrix}
\text{ with sizes }\begin{bmatrix} q \times q & q \times (N-q) \\ (N-q) \times q & (N-q) \times (N-q) \end{bmatrix}

then, the distribution of x1 conditional on x2 = a is multivariate normal (x1|x2 = a) ~ N(μ, Σ) where


\bar{\boldsymbol\mu}
=
\boldsymbol\mu_1 + \boldsymbol\Sigma_{12} \boldsymbol\Sigma_{22}^{-1}
\left(
 \mathbf{a} - \boldsymbol\mu_2
\right)

and covariance matrix


\overline{\boldsymbol\Sigma}
=
\boldsymbol\Sigma_{11} - \boldsymbol\Sigma_{12} \boldsymbol\Sigma_{22}^{-1} \boldsymbol\Sigma_{21}. 
[12]

This matrix is the Schur complement of Σ22 in Σ. This means that to calculate the conditional covariance matrix, one inverts the overall covariance matrix, drops the rows and columns corresponding to the variables being conditioned upon, and then inverts back to get the conditional covariance matrix. Here \boldsymbol\Sigma_{22}^{-1} is the generalized inverse of \boldsymbol\Sigma_{22}.

Note that knowing that x2 = a alters the variance, though the new variance does not depend on the specific value of a; perhaps more surprisingly, the mean is shifted by \boldsymbol\Sigma_{12} \boldsymbol\Sigma_{22}^{-1} \left(\mathbf{a} - \boldsymbol\mu_2 \right); compare this with the situation of not knowing the value of a, in which case x1 would have distribution \mathcal{N}_q \left(\boldsymbol\mu_1, \boldsymbol\Sigma_{11} \right).

An interesting fact derived in order to prove this result, is that the random vectors \mathbf{x}_2 and \mathbf{y}_1=\mathbf{x}_1-\boldsymbol\Sigma_{12}\boldsymbol\Sigma_{22}^{-1}\mathbf{x}_2 are independent.

The matrix Σ12Σ22−1 is known as the matrix of regression coefficients.

Bivariate case[edit]

In the bivariate case where x is partitioned into X1 and X2, the conditional distribution of X1 given X2 is[13]

X_1|X_2=x_2 \ \sim\ \mathcal{N}\left(\mu_1+\frac{\sigma_1}{\sigma_2}\rho( x_2 - \mu_2),\, (1-\rho^2)\sigma_1^2\right).

where \rho is the correlation coefficient between X1 and X2.

Bivariate conditional expectation[edit]

In the general case[edit]


\begin{pmatrix}
 X_1 \\
 X_2
\end{pmatrix}  \sim \mathcal{N} \left( \begin{pmatrix}
 \mu_1 \\
 \mu_2
\end{pmatrix} , \begin{pmatrix}
 \sigma^2_1 &  \sigma_{12} \\
 \sigma_{12} &  \sigma^2_2
\end{pmatrix} \right)

The conditional expectation of X1 given X2 is:

\operatorname{E}(X_1 | X_2=x_2) = \mu_1 + \rho \frac{\sigma_1}{\sigma_2}(x_2 - \mu_2)

Proof: the result is simply obtained taking the expectation of the conditional distribution X_1|X_2 above.

In the standard normal case[edit]


\begin{pmatrix}
 X_1 \\
 X_2
\end{pmatrix}  \sim \mathcal{N} \left( \begin{pmatrix}
 0 \\
 0
\end{pmatrix} , \begin{pmatrix}
 1 & \rho \\
 \rho & 1
\end{pmatrix} \right)

The conditional expectation of X1 given X2 is:

\operatorname{E}(X_1 | X_2=x_2)= \rho x_2

and the conditional expectation of X1 given that X2 is smaller/bigger than z is (Maddala 1983, p. 367[14]) :


\operatorname{E}(X_1 | X_2 < z) = -\rho { \phi(z) \over \Phi(z) } ,

\operatorname{E}(X_1 | X_2 > z) = \rho { \phi(z) \over (1- \Phi(z)) } ,

where the final ratio here is called the inverse Mills ratio.

Proof: the last two results are obtained using the result \operatorname{E}(X_1 | X_2=x_2)= \rho x_2 , so that :
\operatorname{E}(X_1 | X_2 < z) = \rho (X_2 | X_2 < z) and then using the properties of the expectation of a truncated normal distribution.

Marginal distributions[edit]

To obtain the marginal distribution over a subset of multivariate normal random variables, one only needs to drop the irrelevant variables (the variables that one wants to marginalize out) from the mean vector and the covariance matrix. The proof for this follows from the definitions of multivariate normal distributions and linear algebra.[15]

Example

Let x = [X1, X2, X3] be multivariate normal random variables with mean vector μ = [μ1, μ2, μ3] and covariance matrix Σ (standard parametrization for multivariate normal distributions). Then the joint distribution of x′ = [X1, X3] is multivariate normal with mean vector μ′ = [μ1, μ3] and covariance matrix  \boldsymbol\Sigma' =
\begin{bmatrix}
\boldsymbol\Sigma_{11} & \boldsymbol\Sigma_{13} \\
\boldsymbol\Sigma_{31} & \boldsymbol\Sigma_{33}
\end{bmatrix}
.

Affine transformation[edit]

If y = c + Bx is an affine transformation of \mathbf{x}\ \sim \mathcal{N}(\boldsymbol\mu, \boldsymbol\Sigma), where c is an M \times 1 vector of constants and B is a constant M \times N matrix, then y has a multivariate normal distribution with expected value c + and variance BΣBT i.e., \mathbf{y} \sim \mathcal{N} \left(\mathbf{c} + \mathbf{B} \boldsymbol\mu, \mathbf{B} \boldsymbol\Sigma \mathbf{B}^{\rm T}\right). In particular, any subset of the xi has a marginal distribution that is also multivariate normal. To see this, consider the following example: to extract the subset (x1, x2, x4)T, use


\mathbf{B}
=
\begin{bmatrix}
 1 & 0 & 0 & 0 & 0 & \ldots & 0 \\
 0 & 1 & 0 & 0 & 0 & \ldots & 0 \\
 0 & 0 & 0 & 1 & 0 & \ldots & 0
\end{bmatrix}

which extracts the desired elements directly.

Another corollary is that the distribution of Z = b · x, where b is a constant vector of the same length as x and the dot indicates a vector product, is univariate Gaussian with Z\sim\mathcal{N}\left(\mathbf{b}\cdot\boldsymbol\mu, \mathbf{b}^{\rm T}\boldsymbol\Sigma \mathbf{b}\right). This result follows by using


\mathbf{B}=\begin{bmatrix}
b_1    & b_2    & \ldots & b_n  
\end{bmatrix}.

Observe how the positive-definiteness of Σ implies that the variance of the dot product must be positive.

An affine transformation of x such as 2x is not the same as the sum of two independent realisations of x.

Geometric interpretation[edit]

The equidensity contours of a non-singular multivariate normal distribution are ellipsoids (i.e. linear transformations of hyperspheres) centered at the mean.[16] Hence the multivariate normal distribution is an example of the class of elliptical distributions. The directions of the principal axes of the ellipsoids are given by the eigenvectors of the covariance matrix Σ. The squared relative lengths of the principal axes are given by the corresponding eigenvalues.

If Σ = UΛUT = 1/2(1/2)T is an eigendecomposition where the columns of U are unit eigenvectors and Λ is a diagonal matrix of the eigenvalues, then we have

\mathbf{x}\ \sim \mathcal{N}(\boldsymbol\mu, \boldsymbol\Sigma) \iff \mathbf{x}\ \sim \boldsymbol\mu+\mathbf{U}\boldsymbol\Lambda^{1/2}\mathcal{N}(0, \mathbf{I}) \iff \mathbf{x}\ \sim \boldsymbol\mu+\mathbf{U}\mathcal{N}(0, \boldsymbol\Lambda).

Moreover, U can be chosen to be a rotation matrix, as inverting an axis does not have any effect on N(0, Λ), but inverting a column changes the sign of U's determinant. The distribution N(μ, Σ) is in effect N(0, I) scaled by Λ1/2, rotated by U and translated by μ.

Conversely, any choice of μ, full rank matrix U, and positive diagonal entries Λi yields a non-singular multivariate normal distribution. If any Λi is zero and U is square, the resulting covariance matrix UΛUT is singular. Geometrically this means that every contour ellipsoid is infinitely thin and has zero volume in n-dimensional space, as at least one of the principal axes has length of zero.

Estimation of parameters[edit]

The derivation of the maximum-likelihood estimator of the covariance matrix of a multivariate normal distribution is perhaps surprisingly subtle and elegant. See estimation of covariance matrices.

In short, the probability density function (pdf) of a multivariate normal is

f(\mathbf{x})= \frac{1}{\sqrt { (2\pi)^k|\boldsymbol \Sigma| } }  \exp\left(-{1 \over 2} (\mathbf{x}-\boldsymbol\mu)^{\rm T} \boldsymbol\Sigma^{-1} ({\mathbf x}-\boldsymbol\mu)\right)

and the ML estimator of the covariance matrix from a sample of n observations is

\widehat{\boldsymbol\Sigma} = {1 \over n}\sum_{i=1}^n ({\mathbf x}_i-\overline{\mathbf x})({\mathbf x}_i-\overline{\mathbf x})^T

which is simply the sample covariance matrix. This is a biased estimator whose expectation is

E[\widehat{\boldsymbol\Sigma}] = \frac{n-1}{n} \boldsymbol\Sigma.

An unbiased sample covariance is

\widehat{\boldsymbol\Sigma} = {1 \over n-1}\sum_{i=1}^n (\mathbf{x}_i-\overline{\mathbf{x}})(\mathbf{x}_i-\overline{\mathbf{x}})^{\rm T}.

The Fisher information matrix for estimating the parameters of a multivariate normal distribution has a closed form expression. This can be used, for example, to compute the Cramér–Rao bound for parameter estimation in this setting. See Fisher information for more details.

Bayesian inference[edit]

In Bayesian statistics, the conjugate prior of the mean vector is another multivariate normal distribution, and the conjugate prior of the covariance matrix is an inverse-Wishart distribution \mathcal{W}^{-1} . Suppose then that n observations have been made

\mathbf{X} = \{\mathbf{x}_1,\dots,\mathbf{x}_n\} \sim \mathcal{N}(\boldsymbol\mu,\boldsymbol\Sigma)

and that a conjugate prior has been assigned, where

p(\boldsymbol\mu,\boldsymbol\Sigma)=p(\boldsymbol\mu\mid\boldsymbol\Sigma)\ p(\boldsymbol\Sigma),

where

p(\boldsymbol\mu\mid\boldsymbol\Sigma) \sim\mathcal{N}(\boldsymbol\mu_0,m^{-1}\boldsymbol\Sigma) ,

and

p(\boldsymbol\Sigma) \sim \mathcal{W}^{-1}(\boldsymbol\Psi,n_0).

Then,[citation needed]


\begin{array}{rcl}
p(\boldsymbol\mu\mid\boldsymbol\Sigma,\mathbf{X}) & \sim & \mathcal{N}\left(\frac{n\bar{\mathbf{x}} + m\boldsymbol\mu_0}{n+m},\frac{1}{n+m}\boldsymbol\Sigma\right),\\
p(\boldsymbol\Sigma\mid\mathbf{X}) & \sim & \mathcal{W}^{-1}\left(\boldsymbol\Psi+n\mathbf{S}+\frac{nm}{n+m}(\bar{\mathbf{x}}-\boldsymbol\mu_0)(\bar{\mathbf{x}}-\boldsymbol\mu_0)', n+n_0\right),
\end{array}

where


\begin{array}{rcl}
\bar{\mathbf{x}} & = & n^{-1}\sum_{i=1}^{n} \mathbf{x}_i ,\\
\mathbf{S} & = & n^{-1}\sum_{i=1}^{n} (\mathbf{x}_i - \bar{\mathbf{x}})(\mathbf{x}_i - \bar{\mathbf{x}})' .
\end{array}

Multivariate normality tests[edit]

Multivariate normality tests check a given set of data for similarity to the multivariate normal distribution. The null hypothesis is that the data set is similar to the normal distribution, therefore a sufficiently small p-value indicates non-normal data. Multivariate normality tests include the Cox-Small test[17] and Smith and Jain's adaptation[18] of the Friedman-Rafsky test.[19]

Mardia's test[20] is based on multivariate extensions of skewness and kurtosis measures. For a sample {x1, ..., xn} of k-dimensional vectors we compute

\begin{align}
  & \widehat{\boldsymbol\Sigma} = {1 \over n} \sum_{j=1}^n \left(\mathbf{x}_j - \bar{\mathbf{x}}\right)\left(\mathbf{x}_j - \bar{\mathbf{x}}\right)^T \\

  & A = {1 \over 6n} \sum_{i=1}^n \sum_{j=1}^n \left[ (\mathbf{x}_i - \bar{\mathbf{x}})^T\;\widehat{\boldsymbol\Sigma}^{-1} (\mathbf{x}_j - \bar{\mathbf{x}}) \right]^3 \\

  & B = \sqrt{\frac{n}{8k(k+2)}}\left\{{1 \over n} \sum_{i=1}^n \left[ (\mathbf{x}_i - \bar{\mathbf{x}})^T\;\widehat{\boldsymbol\Sigma}^{-1} (\mathbf{x}_i - \bar{\mathbf{x}}) \right]^2 - k(k+2) \right\}
  \end{align}

Under the null hypothesis of multivariate normality, the statistic A will have approximately a chi-squared distribution with 1/6k(k + 1)(k + 2) degrees of freedom, and B will be approximately standard normal N(0,1).

Mardia's kurtosis statistic is skewed and converges very slowly to the limiting normal distribution. For medium size samples (50 \le n < 400), the parameters of the asymptotic distribution of the kurtosis statistic are modified[21] For small sample tests (n<50) empirical critical values are used. Tables of critical values for both statistics are given by Rencher[22] for k=2,3,4.

Mardia's tests are affine invariant but not consistent. For example, the multivariate skewness test is not consistent against symmetric non-normal alternatives.[23]

The BHEP test[24] computes the norm of the difference between the empirical characteristic function and the theoretical characteristic function of the normal distribution. Calculation of the norm is performed in the L2(μ) space of square-integrable functions with respect to the Gaussian weighting function \scriptstyle \mu_\beta(\mathbf{t}) = (2\pi\beta^2)^{-k/2} e^{-|\mathbf{t}|^2/(2\beta^2)}. The test statistic is

\begin{align}
    T_\beta &= \int_{\mathbb{R}^k} \left| {1 \over n} \sum_{j=1}^n e^{i\mathbf{t}^T\widehat{\boldsymbol\Sigma}^{-1/2}(\mathbf{x}_j - \bar{\mathbf{x})}} - e^{-|\mathbf{t}|^2/2} \right|^2 \; \boldsymbol\mu_\beta(\mathbf{t}) d\mathbf{t} \\
            &= {1 \over n^2} \sum_{i,j=1}^n e^{-{\beta \over 2}(\mathbf{x}_i-\mathbf{x}_j)^T\widehat{\boldsymbol\Sigma}^{-1}(\mathbf{x}_i-\mathbf{x}_j)} - \frac{2}{n(1 + \beta^2)^{k/2}}\sum_{i=1}^n e^{ -\frac{\beta^2}{2(1+\beta^2)} (\mathbf{x}_i-\bar{\mathbf{x}})^T\widehat{\boldsymbol\Sigma}^{-1}(\mathbf{x}_i-\bar{\mathbf{x}})} + \frac{1}{(1 + 2\beta^2)^{k/2}}
  \end{align}

The limiting distribution of this test statistic is a weighted sum of chi-squared random variables,[25] however in practice it is more convenient to compute the sample quantiles using the Monte-Carlo simulations.[citation needed]

A detailed survey of these and other test procedures is available.[26]

Drawing values from the distribution[edit]

A widely used method for drawing a random vector x from the N-dimensional multivariate normal distribution with mean vector μ and covariance matrix Σ works as follows:[27]

  1. Find any real matrix A such that AAT = Σ. When Σ is positive-definite, the Cholesky decomposition is typically used, and the extended form of this decomposition can always be used (as the covariance matrix may be only positive semi-definite) in both cases a suitable matrix A is obtained.[citation needed] An alternative is to use the matrix A = ½ obtained from a spectral decomposition Σ = UΛUT of Σ.[citation needed] The former approach is more computationally straightforward but the matrices A change for different orderings of the elements of the random vector, while the latter approach gives matrices that are related by simple re-orderings. In theory both approaches give equally good ways of determining a suitable matrix A, but there are differences in computation time.
  2. Let z = (z1, …, zN)T be a vector whose components are N independent standard normal variates (which can be generated, for example, by using the Box–Muller transform).
  3. Let x be μ + Az. This has the desired distribution due to the affine transformation property.

See also[edit]

References[edit]

  1. ^ Gut, Allan (2009) An Intermediate Course in Probability, Springer. ISBN 9781441901613 (Chapter 5)
  2. ^ UIUC, Lecture 21. The Multivariate Normal Distribution, 21.5:"Finding the Density".
  3. ^ Hamedani, G. G.; Tata, M. N. (1975). "On the determination of the bivariate normal distribution from distributions of linear combinations of the variables". The American Mathematical Monthly 82 (9): 913–915. doi:10.2307/2318494. 
  4. ^ Wyatt, John. "Linear least mean-squared error estimation". Lecture notes course on applied probability. Retrieved 23 January 2012. 
  5. ^ Rao, C.R. (1973). Linear Statistical Inference and Its Applications. New York: Wiley. pp. 527–528. 
  6. ^ Tong, T. (2010) Multiple Linear Regression : MLE and Its Distributional Results, Lecture Notes
  7. ^ Gokhale, DV; Ahmed, NA; Res, BC; Piscataway, NJ (May 1989). "Entropy Expressions and Their Estimators for Multivariate Distributions". Information Theory, IEEE Transactions on 35 (3): 688–692. doi:10.1109/18.30996. 
  8. ^ J. Duchi, Derivations for Linear Algebra and Optimization [1]. pp. 13
  9. ^ a b Bensimhoun Michael, N-Dimensional Cumulative Function, And Other Useful Facts About Gaussians and Normal Densities (2006)
  10. ^ Genz, Alan (2009). Computation of Multivariate Normal and t Probabilities. Springer. ISBN 978-3-642-01689-9. 
  11. ^ Siotani, Minoru (1964). "Tolerance regions for a multivariate normal population". Annals of the Institute of Statistical Mathematics 16 (1): 135–153. doi:10.1007/BF02868568. 
  12. ^ Eaton, Morris L. (1983). Multivariate Statistics: a Vector Space Approach. John Wiley and Sons. pp. 116–117. ISBN 0-471-02776-6. 
  13. ^ Jensen, J (2000). Statistics for Petroleum Engineers and Geoscientists. Amsterdam: Elsevier. p. 207. 
  14. ^ Gangadharrao, Maddala (1983). Limited Dependent and Qualitative Variables in Econometrics. Cambridge University Press. 
  15. ^ The formal proof for marginal distribution is shown here http://fourier.eng.hmc.edu/e161/lectures/gaussianprocess/node7.html
  16. ^ Nikolaus Hansen. "The CMA Evolution Strategy: A Tutorial" (PDF). 
  17. ^ Cox, D. R.; Small, N. J. H. (1978). "Testing multivariate normality". Biometrika 65 (2): 263. doi:10.1093/biomet/65.2.263.  edit
  18. ^ Smith, S. P.; Jain, A. K. (1988). "A test to determine the multivariate normality of a data set". IEEE Transactions on Pattern Analysis and Machine Intelligence 10 (5): 757. doi:10.1109/34.6789.  edit
  19. ^ Friedman, J. H.; Rafsky, L. C. (1979). "Multivariate Generalizations of the Wald-Wolfowitz and Smirnov Two-Sample Tests". The Annals of Statistics 7 (4): 697. doi:10.1214/aos/1176344722.  edit
  20. ^ Mardia, K. V. (1970). "Measures of multivariate skewness and kurtosis with applications". Biometrika 57 (3): 519–530. doi:10.1093/biomet/57.3.519. 
  21. ^ Rencher (1995), pages 112-113.
  22. ^ Rencher (1995), pages 493-495.
  23. ^ Baringhaus, L.; Henze, N. (1991). "Limit distributions for measures of multivariate skewness and kurtosis based on projections". Journal of Multivariate Analysis 38: 51. doi:10.1016/0047-259X(91)90031-V.  edit
  24. ^ Epps, Lawrence B.; Pulley, Lawrence B. (1983). "A test for normality based on the empirical characteristic function". Biometrika 70 (3): 723–726. doi:10.1093/biomet/70.3.723. 
  25. ^ Baringhaus, L.; Henze, N. (1988). "A consistent test for multivariate normality based on the empirical characteristic function". Metrika 35 (1): 339–348. doi:10.1007/BF02613322. 
  26. ^ Henze, Norbert (2002). "Invariant tests for multivariate normality: a critical review". Statistical Papers 43 (4): 467–506. doi:10.1007/s00362-002-0119-6. 
  27. ^ Gentle, J.E. (2009). Computational Statistics. New York: Springer. pp. 315–316. doi:10.1007/978-0-387-98144-4. 

Literature[edit]

  • Rencher, A.C. (1995). Methods of Multivariate Analysis. New York: Wiley.