polars.DataTypeExpr.arr.width#

DataTypeExpr.arr.width() Expr[source]#

Get the array width.

Examples

>>> pl.select(pl.Array(pl.Int8, (1, 2, 3)).to_dtype_expr().arr.width())
shape: (1, 1)
┌─────────┐
│ literal │
│ ---     │
│ u32     │
╞═════════╡
│ 1       │
└─────────┘