Covariance
The covariance — usually denoted as Cov — is a statistical parameter used to compare
two real random variables on the same sample space.
It is defined as the expectation (or mean value)
of the product of the deviations (from their respective mean values)
of the two variables.
The value of the covariance depends on how clearly a linear trend is pronounced.
- If one variable increases (in the mean) with the other, then the covariance is positive.
- It is negative if one variable decreases when the other one tends to increase.
- And it is 0 if the two variables are (stochastically) independent of each other.
To see how distinct the trend is, and for comparisons that are independent of the scale used, the normed version of the covariance — the correlation coefficient — has to be used.
Formal definition
The covariance of two real random variables X and Y
with expectation (mean value)
is defined by
Remark:
If the two random variables are the same then
their covariance is equal to the variance of the single variable: Cov(X,X) = Var(X).