Multivariate normal cumulative distribution function
y = mvncdf(X)
y = mvncdf(X,mu,SIGMA)
y = mvncdf(xl,xu,mu,SIGMA)
[y,err] = mvncdf(...)
[...] = mvncdf(...,options)
y = mvncdf(X) returns the
cumulative probability of the multivariate normal distribution with
zero mean and identity covariance matrix, evaluated at each row of
Rows of the n-by-d matrix
to observations or points, and columns correspond to variables or
y is an n-by-
y = mvncdf(X,mu,SIGMA) returns
the cumulative probability of the multivariate normal distribution
mu and covariance
evaluated at each row of
1-by-d vector, and
a d-by-d symmetric, positive
mu can also be a scalar value,
mvncdf replicates to match the size of
If the covariance matrix is diagonal, containing variances along the
diagonal and zero covariances off the diagonal,
also be specified as a
containing just the diagonal. Pass in the empty matrix
use as its default value when you want to only specify
The multivariate normal cumulative probability at
defined as the probability that a random vector
distributed as multivariate normal, will fall within the semi-infinite
rectangle with upper limits defined by
X, for example,
y = mvncdf(xl,xu,mu,SIGMA) returns
the multivariate normal cumulative probability evaluated over the
rectangle with lower and upper limits defined by
[y,err] = mvncdf(...) returns
an estimate of the error in
y. For bivariate and
mvncdf uses adaptive
quadrature on a transformation of the t density,
based on methods developed by Drezner and Wesolowsky and by Genz,
as described in the references. The default absolute error tolerance
for these cases is
1e-8. For four or more dimensions,
a quasi-Monte Carlo integration algorithm based on methods developed
by Genz and Bretz, as described in the references. The default absolute
error tolerance for these cases is
[...] = mvncdf(...,options) specifies
control parameters for the numerical integration used to compute
This argument can be created by a call to
'TolFun' — Maximum absolute
error tolerance. Default is
1e-8 when d <
1e-4 when d ≥ 4.
'MaxFunEvals' — Maximum
number of integrand evaluations allowed when d ≥
4. Default is
ignored when d < 4.
'Display' — Level of display
output. Choices are
'off' (the default),
'Display' is ignored
when d < 4.
Compute and plot the cdf of a multivariate normal distribution with parameters
mu = [1 -1] and
SIGMA = [.9 .4; .4 .3].
mu = [1 -1]; SIGMA = [.9 .4; .4 .3]; figure; [X1,X2] = meshgrid(linspace(-1,3,25)',linspace(-3,1,25)'); X = [X1(:) X2(:)]; p = mvncdf(X,mu,SIGMA); surf(X1,X2,reshape(p,25,25));
 Drezner, Z. "Computation of the Trivariate Normal Integral." Mathematics of Computation. Vol. 63, 1994, pp. 289–294.
 Drezner, Z., and G. O. Wesolowsky. "On the Computation of the Bivariate Normal Integral." Journal of Statistical Computation and Simulation. Vol. 35, 1989, pp. 101–107.
 Genz, A. "Numerical Computation of Rectangular Bivariate and Trivariate Normal and t Probabilities." Statistics and Computing. Vol. 14, No. 3, 2004, pp. 251–260.
 Genz, A., and F. Bretz. "Numerical Computation of Multivariate t Probabilities with Application to Power Calculation of Multiple Contrasts." Journal of Statistical Computation and Simulation. Vol. 63, 1999, pp. 361–378.
 Genz, A., and F. Bretz. "Comparison of Methods for the Computation of Multivariate t Probabilities." Journal of Computational and Graphical Statistics. Vol. 11, No. 4, 2002, pp. 950–971.