Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
Mathematica > Data Manipulation > Statistical Data Analysis > Descriptive Statistics > Covariance >
Mathematica > Mathematics and Algorithms > Statistical Data Analysis > Descriptive Statistics > Covariance >

Covariance

Updated In 8 Graphic
Covariance
gives the covariance between the vectors and .
Covariance[m]
gives the covariance matrix for the matrix m.
Covariance
gives the covariance matrix for the matrices and .
Covariance[dist]
gives the covariance matrix for the multivariate symbolic distribution dist.
Covariance
gives the ^(th) covariance for the multivariate symbolic distribution dist.
  • Covariance gives the unbiased estimate of the covariance between and .
  • The lists and must be the same length.
  • For a matrix m with columns, Covariance[m] is a × matrix of the covariances between columns of m.
  • For an × matrix and an × matrix , Covariance is a × matrix of the covariances between columns of and columns of .
Covariance between two vectors:
Covariance matrix for a matrix:
Covariance matrix for two matrices:
Covariance between two vectors:
In[1]:=
Click for copyable input
Out[1]=
 
Covariance matrix for a matrix:
In[1]:=
Click for copyable input
Out[1]//MatrixForm=
 
Covariance matrix for two matrices:
In[1]:=
Click for copyable input
Out[1]//MatrixForm=
Covariances for machine-precision reals:
Use arbitrary precision:
Find the covariance between vectors of complexes:
Compute the covariance of a SparseArray:
Compute the covariance of two financial time series:
The covariance tends to be large only on the diagonal of a random matrix:
The covariance of a list with itself is the variance:
The diagonal of a covariance matrix is the variance:
A covariance matrix scaled by standard deviations is a correlation matrix:
Compute the covariance for a GCD array:
New in 6 | Last modified in 8
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team
Format:   HTML  |  CDF