Table of Contents
The COVARIANCE.S function in Excel is used to calculate the covariance between two sets of data. It measures the relationship between the two sets by determining how much they vary together. To use this function, first select the cell where you want the result to appear. Then, type “=COVARIANCE.S(” and select the first set of data, followed by a comma. Next, select the second set of data and close the parentheses. Press Enter to calculate the covariance. The result will be a numerical value representing the strength and direction of the relationship between the two sets of data. This function is useful for analyzing the correlation between two variables and can be used in a variety of statistical and financial applications.
This article describes the formula syntax and usage of the COVARIANCE.S function in Microsoft Excel.
Returns the sample covariance, the average of the products of deviations for each data point pair in two data sets.
Syntax
COVARIANCE.S(array1,array2)
The COVARIANCE.S function syntax has the following arguments:
Array1 Required. The first cell range of integers.
Array2 Required. The second cell range of integers.
Remarks
The arguments must either be numbers or be names, arrays, or references that contain numbers.
If an array or reference argument contains text, logical values, or empty cells, those values are ignored; however, cells with the value zero are included.
If array1 and array2 have different numbers of data points, COVARIANCE.S returns the #N/A error value.
If either array1 or array2 is empty or contains only 1 data point each, COVARIANCE.S returns the #DIV/0! error value.
Example
Copy the example data in the following table, and paste it in cell A1 of a new Excel worksheet. For formulas to show results, select them, press F2, and then press Enter. If you need to, you can adjust the column widths to see all the data.
Formula | Description | Result |
=COVARIANCE.S({2,4,8},{5,11,12}) | Sample covariance for the data points entered as an array in the function. | 9.666666667 |
2 | 5 | |
4 | 11 | |
8 | 12 | |
Formula | Description | Result |
=COVARIANCE.S(A3:A5,B3:B5) | Sample covariance for the identical data points, but entered as cell ranges in the function. | 9.666666667 |
Cite this article
stats writer (2024). How can I calculate covariance using the function COVARIANCE.S in Excel?. PSYCHOLOGICAL SCALES. Retrieved from https://scales.arabpsychology.com/stats/how-can-i-calculate-covariance-using-the-function-covariance-s-in-excel/
stats writer. "How can I calculate covariance using the function COVARIANCE.S in Excel?." PSYCHOLOGICAL SCALES, 29 Jun. 2024, https://scales.arabpsychology.com/stats/how-can-i-calculate-covariance-using-the-function-covariance-s-in-excel/.
stats writer. "How can I calculate covariance using the function COVARIANCE.S in Excel?." PSYCHOLOGICAL SCALES, 2024. https://scales.arabpsychology.com/stats/how-can-i-calculate-covariance-using-the-function-covariance-s-in-excel/.
stats writer (2024) 'How can I calculate covariance using the function COVARIANCE.S in Excel?', PSYCHOLOGICAL SCALES. Available at: https://scales.arabpsychology.com/stats/how-can-i-calculate-covariance-using-the-function-covariance-s-in-excel/.
[1] stats writer, "How can I calculate covariance using the function COVARIANCE.S in Excel?," PSYCHOLOGICAL SCALES, vol. X, no. Y, ص Z-Z, June, 2024.
stats writer. How can I calculate covariance using the function COVARIANCE.S in Excel?. PSYCHOLOGICAL SCALES. 2024;vol(issue):pages.
