Truncate Paths
Trim each path to the window between two anchor events (inclusive).
For each path, the first occurrence of start_event and the first occurrence
of end_event that comes after it are found. Events outside this window are
dropped. Paths that do not contain both anchors in the correct order are
removed entirely. The reserved names path_start / path_end are valid
anchors, e.g. end_event="path_end" keeps everything after start_event.
Usage
stream.truncate_paths(start_event="registration", end_event="purchase")
Parameters
| Parameter | Type | Description |
|---|---|---|
start_event | str | Name of the event that marks the start of the window. |
end_event | str | Name of the event that marks the end of the window. |
path_col | str, optional | Path ID column override; defaults to schema.path_col. |
event_col | str, optional | Event column override; defaults to schema.event_col. |