What is Covariance?

Covariance is a statistical measure that determines the direction and strength of the relationship between two variables. It helps to understand how two variables move together. A positive covariance indicates that both variables tend to increase or decrease together, while a negative covariance shows that one variable increases as the other decreases.

Covariance Calculation Formula: Covariance is calculated as the average of the products of the differences between each value of the variables and their means. The formula for calculating covariance is as follows:

Covariance = (1/n) * Σ[(X_i - Mean(X)) * (Y_i - Mean(Y))] Here, X_i and Y_i are the values of the first and second variables, respectively, and Mean(X) and Mean(Y) are their mean values.

Meaning of Covariance

Covariance shows how two variables move together:
  • Positive Covariance: Both variables increase or decrease together. For example, stock prices and a market index often move together. When stock prices rise, the market index may also rise.
  • Negative Covariance: One variable increases while the other decreases. For example, the price of one asset may increase while the price of another decreases, indicating an inverse relationship between the two assets.
  • Magnitude: The magnitude of covariance indicates the strength of the relationship between the variables. A large positive or negative covariance suggests a strong relationship, while a small covariance indicates a weak relationship.

Example Calculation

For example, when calculating the covariance between the prices of two stocks, you consider how their deviations from their means relate to each other. If stock 1 and stock 2 prices generally move in the same direction, you'll get a positive covariance. If they move in opposite directions, you'll get a negative covariance.

The value of covariance helps you understand how much and in what way two variables move together. A positive value shows similar movements, while a negative value indicates opposite movements.

Evaluation

Covariance is an important measure for determining the direction of the relationship between two variables. However, the magnitude of covariance not only reflects the strength of the relationship but also includes the influence of the scales of the variables. Therefore, the standardized version of covariance, the correlation coefficient, provides a clearer expression of the strength of the relationship.