Covariance Matrix Calculator

Let $\mathbf{x}_1,\ldots,\mathbf{x}_m$ be $m$ vectors in $\mathbf{R}^n$, the corresponding sample covariance matrix is $m\times m$ matrix $C=[c_{ij}]$ whose entries are the dot product of the mean-deviation form of the vectors: \[ c_{ij} = \frac{(\mathbf{x}_i-\overline{\mathbf{x}_i})\cdot (\mathbf{x}_j-\overline{\mathbf{x}_j})}{n-1},\;\mbox{where}\;i,j=1,\ldots,m \] Similarly, the entries of the population covariance matrix are \[ c_{ij} = \frac{(\mathbf{x}_i-\overline{\mathbf{x}_i})\cdot (\mathbf{x}_j-\overline{\mathbf{x}_j})}{n},\;\mbox{where}\;i,j=1,\ldots,m \]

This application requires the input data in the form of $n\times m$ matrix whose $k^\mathrm{th}$ column is vector $x_k$, See Input Matrix for how to enter data to a matrix.

Covariance Matrix Calculator