Skip to content

LazyFrame.groupby

groupby

groupby(by: Union[str, list[str]]) -> LazyGrouppedFrame

Group the relation by one or more columns.

Parameters:

Name Type Description Default
by str | list[str]

The column(s) to group by.

required

Returns:

Name Type Description
LazyGrouppedFrame LazyGrouppedFrame

A new LazyGrouppedFrame with the grouped data.