polars.DataFrame.shape

property DataFrame.shape: Tuple[int, int]

Get the shape of the DataFrame.

Examples

>>> df = pl.DataFrame({"foo": [1, 2, 3, 4, 5]})
>>> df.shape
(5, 1)