pm4py.filtering.filter_ocel_objects#
- pm4py.filtering.filter_ocel_objects(ocel: OCEL, object_identifiers: Collection[str], positive: bool = True, level: int = 1) OCEL [source]#
Filters the object identifiers of an object-centric event log.
- Return type:
- Parameters:
ocel (
OCEL
) – Object-centric event log.object_identifiers – Object identifiers to keep or remove.
positive (
bool
) – Boolean indicating whether to keep (True) or remove (False) the specified object identifiers.level (
int
) – Recursively expands the set of object identifiers until the specified level.
- Returns:
Filtered OCEL.
import pm4py ocel = pm4py.read_ocel('log.jsonocel') filtered_ocel = pm4py.filter_ocel_objects( ocel, ['o1'], level=1 )