[Table of Contents] [docx version]
SpreadsheetML Reference Material - Table of Contents
COVAR ( array-1 , array-2 )
Description: Computes covariance; that is, the average of the products of deviations for each data point pair in the two cell ranges designated by array-1 and array-2.
Mathematical Formula:
The covariance is:
where x and y are the sample means AVERAGE(array-1) and AVERAGE(array-2), and n is the sample size.
Arguments:
Name |
Type |
Description |
array-1 |
number, name, array, reference to number |
If an array or reference argument contains text, logical values, or empty cells, those values are ignored; however, cells with the value 0 are included. |
array-2 |
Return Type and Value: number – The covariance.
However, if
• array-1 and array-2 have a different number of data points, the return value is unspecified.
• array-1 or array-2 is empty, the return value is unspecified.
[Example:
COVAR({2.532,5.621;2.1,3.4},{5.32,2.765;5.2,6.7}) results in -1.375374
end example]