pandas.ArrowDtype #
- 熊猫类 。ArrowDtype ( pyarrow_dtype ) [来源] #
PyArrow 数据类型的 ExtensionDtype。
警告
ArrowDtype 被认为是实验性的。 API 的实现和部分可能会在没有警告的情况下发生更改。
虽然大多数
dtype
参数可以接受“字符串”构造函数,例如"int64[pyarrow]"
,如果数据类型包含诸如 之类的参数,则 ArrowDtype 很有用pyarrow.timestamp
。- 参数:
- pyarrow_dtype pa.DataType
pyarrow.DataType的实例。
- 返回:
- 箭头D型
例子
>>> import pyarrow as pa >>> pd.ArrowDtype(pa.int64()) int64[pyarrow]
带参数的类型必须使用 ArrowDtype 构造。
>>> pd.ArrowDtype(pa.timestamp("s", tz="America/New_York")) timestamp[s, tz=America/New_York][pyarrow] >>> pd.ArrowDtype(pa.list_(pa.int64())) list<item: int64>[pyarrow]
属性
pyarrow_dtype
方法
没有任何