pymovements.events.EventDataFrame.split#

EventDataFrame.split(by: Sequence[str]) list[EventDataFrame][source]#

Split the EventDataFrame into multiple frames based on specified column(s).

Parameters:

by (Sequence[str]) – Column name(s) to split the DataFrame by. If a single string is provided, it will be used as a single column name. If a list is provided, the DataFrame will be split by unique combinations of values in all specified columns.

Returns:

A list of new EventDataFrame instances, each containing a partition of the original data with all metadata and configurations preserved.

Return type:

list[EventDataFrame]