Formualizer Docs

COVARIANCE.P

Returns population covariance for two paired numeric data sets.

COVARIANCE.P measures joint variability using n in the denominator.

The Formualizer engine in this repository at 0.15.0 plus unreleased changes computes the example results. Known differences from Excel are listed on this page.

Syntax

=COVARIANCE.P(array1, array2)

Arguments

ArgumentTypeRequiredDefault
array1number (range)Required—
array2number (range)Required—

Remarks

  • Arrays must resolve to the same number of numeric points.
  • Uses population scaling (/ n) rather than sample scaling.
  • Positive output indicates same-direction movement; negative output indicates opposite movement.
  • Pairing and shape mismatches return spreadsheet errors from paired-array validation.

Examples

Evaluate matched observations in two equally sized arrays.

Formula =COVARIANCE.P({1,2,3,4},{1,4,5,7})

Expected result 2.375

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Reverse the second series to compare opposite movement.

Formula =COVARIANCE.P({1,2,3,4},{7,5,4,1})

Expected result -2.375

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Use two observations that follow a perfect positive linear pattern.

Formula =COVARIANCE.P({1,2},{2,4})

Expected result 0.5

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Each observation needs a partner in the other array.

Formula =COVARIANCE.P({1,2,3,4},{1,4,5})

Expected result #N/A

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Positive population covariance

Formula =COVARIANCE.P({1,3,5},{2,4,6})

Expected result 2.66666666666667

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Negative population covariance

Formula =COVARIANCE.P({1,2,3},{3,2,1})

Expected result -0.666666666666667

Try this formula

This editor runs the published Formualizer 0.14.0 package, so the last digits can differ and functions newer than that release return #NAME?.

Implementation

Engine source

On this page