pyarrow.compute.count_substring

pyarrow.compute.count_substring(array, pattern, *, ignore_case=False)[source]

Count the occurrences of substring pattern in each value of a string array.

Parameters
  • array (pyarrow.Array or pyarrow.ChunkedArray) –

  • pattern (str) – pattern to search for exact matches

  • ignore_case (bool, default False) – Ignore case while searching.

Returns

result (pyarrow.Array or pyarrow.ChunkedArray)