pyarrow.compute.index_in

pyarrow.compute.index_in(values, *, memory_pool=None, options=None, value_set, skip_nulls=False)

Return index of each element in a set of values.

For each element in values, return its index in a given set of values, or null if it is not found there. The set of values to look for must be given in SetLookupOptions. By default, nulls are matched against the value set, this can be changed in SetLookupOptions.

Parameters
  • values (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.

  • options (pyarrow.compute.SetLookupOptions, optional) – Parameters altering compute function semantics.

  • value_set (optional) – Parameter for SetLookupOptions constructor. Either options or value_set can be passed, but not both at the same time.

  • skip_nulls (optional) – Parameter for SetLookupOptions constructor. Either options or skip_nulls can be passed, but not both at the same time.