pyarrow.compute.utf8_replace_slice(strings, *, memory_pool=None, options=None, start, stop, replacement)

Replace a slice of a string with replacement.

For each string in strings, replace a slice of the string defined by start`and `stop with replacement. start is inclusive and stop is exclusive, and both are measured in codeunits. Null values emit null.

  • strings (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.ReplaceSliceOptions, optional) – Parameters altering compute function semantics

  • **kwargs (optional) – Parameters for ReplaceSliceOptions constructor. Either options or **kwargs can be passed, but not both at the same time.