cudf.core.dtypes.ListDtype#
- class cudf.core.dtypes.ListDtype(element_type: Dtype)[source]#
Type to represent list data.
- Parameters:
- element_typeobject
A dtype with which represents the element types in the list.
Attributes
element_type
leaf_type
Methods
from_arrow(typ)Creates a
ListDtypefrompyarrow.ListType.to_arrow()Convert to a
pyarrow.ListTypeExamples
>>> import cudf >>> list_dtype = cudf.ListDtype("int32") >>> list_dtype ListDtype(int32)
A nested list dtype can be created by:
>>> nested_list_dtype = cudf.ListDtype(list_dtype) >>> nested_list_dtype ListDtype(ListDtype(int32))