polars.Expr.reshape

Expr.reshape(dims: Tuple[int, ...]) polars.internals.expr.Expr

Reshape this Expr to a flat series, shape: (len,) or a List series, shape: (rows, cols)

if a -1 is used in any of the dimensions, that dimension is inferred.

Parameters
dims

Tuple of the dimension sizes

Returns
Expr