daft.Series.from_pylist
daft.Series.from_pylist#
- static Series.from_pylist(data: list, name: str = 'list_series', pyobj: str = 'allow') daft.series.Series [source]#
Construct a Series from a Python list.
- The resulting type depends on the setting of pyobjects:
"allow"
: Arrow-backed types if possible, else PyObject;"disallow"
: Arrow-backed types only, raising error if not convertible;"force"
: Store as PyObject types.
- Parameters
data – The Python list whose data we wish to put in the Series.
name – The name associated with the Series; this is usually the column name.
pyobj – Whether we want to
"allow"
coercion to Arrow types,"disallow"
falling back to Python type representation, or"force"
the data to only have a Python type representation. Default is"allow"
.