polars.DataFrame.width

property DataFrame.width: int

Get the width of the DataFrame.

Examples

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