Covariance - Covariation
- a type of covariation that summarizes interrelation of 2 variables by outputting a scalar value ranging from (-∞, +∞)
- is a stepping stone for correlation
- is a central mixed moment of order 𝑘1=1 & 𝑘2=1
Covariance - Formula
Population Covariance Formula
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐄[(𝑥𝑖 - 𝜇𝑥)(𝑦𝑖 - 𝜇𝑦)]
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐄[𝑥𝑖𝑦𝑖] - 𝜇𝑥𝜇𝑦
-
Click here to expand...
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐄[𝑥𝑖𝑦𝑖 - 𝜇𝑥𝑦𝑖 - 𝜇𝑦𝑥𝑖 + 𝜇𝑥𝜇𝑦]
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐄[𝑥𝑖𝑦𝑖] - 𝐄[𝜇𝑥𝑦𝑖] - 𝐄[𝜇𝑦𝑥𝑖] + 𝐄[𝜇𝑥𝜇𝑦]
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐄[𝑥𝑖𝑦𝑖] - 𝜇𝑥𝐄[𝑦𝑖] - 𝜇𝑦𝐄[𝑥𝑖] + 𝐄[𝜇𝑥𝜇𝑦]
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐄[𝑥𝑖𝑦𝑖] - 𝜇𝑥𝜇𝑦 - 𝜇𝑦𝜇𝑥 + 𝜇𝑥𝜇𝑦
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐄[𝑥𝑖𝑦𝑖] - 𝜇𝑥𝜇𝑦
- 𝐶𝑜𝑣(𝑋,𝑌) = [𝛴1≤𝑖≤𝑛(𝑥𝑖 - 𝜇𝑥)(𝑦𝑖 - 𝜇𝑦)] / (𝑛)
- 𝐶𝑜𝑣(𝑋,𝑌) = [𝛴1≤𝑖≤𝑛(𝑥𝑖𝑦𝑖)]/(𝑛) - 𝜇𝑥𝜇𝑦
where:
- 𝜇𝑥- true average (population mean) of all 𝑥 values
- 𝜇𝑦- true average (population mean) of all 𝑦 values
Sample Covariance Formula
- 𝐶𝑜𝑣’(𝑋,𝑌) = 𝐄[(𝑥𝑖 - 𝑥̅)(𝑦𝑖 - 𝑦̅)]
- 𝐶𝑜𝑣’(𝑋,𝑌) = [𝛴1≤𝑖≤𝑛(𝑥𝑖 - 𝑥̅)(𝑦𝑖 - 𝑦̅)] / (𝑛 - 1)
- 𝐶𝑜𝑣’(𝑋,𝑌) = [𝛴1≤𝑖≤𝑛(𝑥𝑖𝑦𝑖)]/(𝑛 - 1) - 𝑥̅𝑦̅
where:
- 𝑥̅ - estimated average (sample mean) of all 𝑥 values
- 𝑦̅ - estimated average (sample mean) of all 𝑦 values
Covariance - With Itself is Variance
- 𝐶𝑜𝑣(𝑋,𝑋) = 𝐄[(𝑥𝑖 - 𝜇𝑥)(𝑥𝑖 - 𝜇𝑥)]
- 𝐶𝑜𝑣(𝑋,𝑋) = [𝛴1≤𝑖≤𝑛(𝑥𝑖 - 𝜇𝑥)(𝑥𝑖 - 𝜇𝑥)] / (𝑛)
- 𝐶𝑜𝑣(𝑋,𝑋) = [𝛴1≤𝑖≤𝑛(𝑥𝑖 - 𝜇𝑥)2] / (𝑛)
- 𝐶𝑜𝑣(𝑋,𝑋) = 𝑉𝑎𝑟(𝑋)
Covariance - Diagrams
Covariance - Properties
Link to original
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐄[(𝑋-𝐄[𝑋])(𝑌-𝐄[𝑌])] = 𝐄[𝑋𝑌] - 𝐄[𝑋]𝐄[𝑌]
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐄[(𝑋-𝜇𝑋)(𝑌-𝜇𝑌)] = 𝐄[𝑋𝑌] - 𝜇𝑋𝜇𝑌
- 𝐶𝑜𝑣(𝑋,𝑌) = 𝐶𝑜𝑣(𝑌,𝑋)
- 𝐶𝑜𝑣(𝑎𝑋 + 𝑏, 𝑐𝑌 + 𝑑) = 𝑎𝑐𝐶𝑜𝑣(𝑋,𝑌)
- 𝐶𝑜𝑣(𝑎𝑋 + 𝑏𝑌, 𝑐𝑍 + 𝑑𝑊) = 𝑎𝑐𝐶𝑜𝑣(𝑋,𝑍) + 𝑎𝑑𝐶𝑜𝑣(𝑋,𝑊) + 𝑏𝑐𝐶𝑜𝑣(𝑌,𝑍) + 𝑏𝑑𝐶𝑜𝑣(𝑌,𝑊)
- 𝐶𝑜𝑣(𝑋,𝑌) = 0 # for independent 𝑋 and 𝑌
Covariance - Other
