pyarrow.array(sequence, DataType type=None, MemoryPool memory_pool=None, size=None)

Create pyarrow.Array instance from a Python sequence

  • sequence (sequence-like or iterable object of Python objects.) – If both type and size are specified may be a single use iterable.
  • type (pyarrow.DataType, optional) – If not passed, will be inferred from the data
  • memory_pool (pyarrow.MemoryPool, optional) – If not passed, will allocate memory from the currently-set default memory pool
  • size (int64, optional) – Size of the elements. If the imput is larger than size bail at this length. For iterators, if size is larger than the input iterator this will be treated as a “max size”, but will involve an initial allocation of size followed by a resize to the actual size (so if you know the exact size specifying it correctly will give you better performance).

array (pyarrow.Array)