Check Sheet Logo
Check Sheet

COVARIANCE.S

The COVARIANCE.S function calculates the covariance between two sets of data. It measures how much two variables change together, taking into account their standard deviations. This function is commonly used in statistics to understand the relationship between two sets of variables.

Usage

Use the COVARIANCE.S formula with the syntax shown below, it has 2 required parameters:

=COVARIANCE.S(data_y, data_x)
Parameters:
  1. data_y (required):
    The array or range containing the first set of data values.
  2. data_x (required):
    The array or range containing the second set of data values.

Examples

Here are a few example use cases that explain how to use the COVARIANCE.S formula in Google Sheets.

Analyzing the relationship between two variables

Using COVARIANCE.S, you can quickly calculate the covariance between two sets of data. This helps you understand how much two variables change together and whether they have a positive or negative relationship.

Forecasting trends

By analyzing the covariance between two sets of data, you can identify trends and use this information to make predictions about future behavior. For example, if you find a positive covariance between sales and marketing spend, you might predict that increasing marketing spend will lead to higher sales.

Comparing the variability of two data sets

The covariance between two sets of data can also help you compare how much each set varies. For example, if the covariance between two sets of data is high, it means that both sets of data vary by similar amounts. If the covariance is low, it means that one set of data varies more than the other.

Common Mistakes

COVARIANCE.S not working? Here are some common mistakes people make when using the COVARIANCE.S Google Sheets Formula:

Incorrect range references

One of the most common mistakes when using COVARIANCE.S is referencing the wrong range of cells. Make sure that the range references for data_y and data_x are correct and include all the necessary data.

Incorrect order of data_y and data_x

Make sure that data_y is the first argument and data_x is the second argument. Switching the order of the arguments will result in an error or incorrect results.

Missing data

COVARIANCE.S will return an error if there are any blank cells or cells with text in the data range. Make sure that all of the cells in the data range contain numeric data.

The following functions are similar to COVARIANCE.S or are often used with it in a formula:

  • CORREL

    The CORREL formula returns the correlation coefficient between two sets of data. This coefficient represents the strength of the linear relationship between the two sets of data, with values ranging from -1 (perfect negative correlation) to 1 (perfect positive correlation).

  • COVARIANCE.P

    The COVARIANCE.P function in Google Sheets calculates the covariance of two datasets. Covariance is a measure of how two variables change together, and this function is commonly used to understand the relationship between two sets of data. This function uses the formula for population covariance, so it is best suited for larger datasets.

  • STDEV.S

    The STDEV.S formula calculates the standard deviation of a sample of data. It is commonly used to measure the amount of variation or dispersion of a set of values from their average. This formula accepts up to 255 arguments, which can be numbers, arrays, or references that contain numbers. The result is a measure of how spread out the data is, with a larger standard deviation indicating greater variability.

  • AVERAGE

    The AVERAGE function calculates the average (arithmetic mean) of the values passed to it. It is commonly used to find the average of a range of cells containing numerical data.

  • SUM

    The SUM function in Google Sheets adds up a range of numbers. This function is most commonly used to sum the values in a range of cells.

Learn More

You can learn more about the COVARIANCE.S Google Sheets function on Google Support.