polars.DataTypeExpr.arr.shape#

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

Get the array shape.

Examples

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