pyarrow.compute.hash_variance

pyarrow.compute.hash_variance(array, group_id_array, *, memory_pool=None)

Calculate the variance of a numeric array.

The number of degrees of freedom can be controlled using VarianceOptions. By default (ddof = 0), the population variance is calculated. Nulls are ignored. If there are not enough non-null values in the array to satisfy ddof, null is returned.

Parameters
  • array (Array-like or scalar-like) – Argument to compute function

  • group_id_array (Array-like or scalar-like) – Argument to compute function

  • memory_pool (pyarrow.MemoryPool, optional) – If not passed, will allocate memory from the default memory pool.