Time Dimension Indicators¶
process_performance_indicators.indicators.time.instances
¶
lead_time(event_log: pd.DataFrame, instance_id: str) -> pd.Timedelta
¶
The total elapsed time of the activity instance, measured as the sum of the elapsed time between the start and complete events of the activity instance, and the elapsed time between the complete event of the activity instance that precedes the current activity instance, and the start event of the current activity instance.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
instance_id
|
str
|
The instance id. |
required |
Source code in process_performance_indicators/indicators/time/instances.py
service_and_lead_time_ratio(event_log: pd.DataFrame, instance_id: str) -> float
¶
The ratio between the elapsed time between the start and complete events of the activity instance, and the total elapsed time of the activity instance.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
instance_id
|
str
|
The instance id. |
required |
Source code in process_performance_indicators/indicators/time/instances.py
service_time(event_log: pd.DataFrame, instance_id: str) -> pd.Timedelta
¶
The elapsed time between the start and complete events of the activity instance.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
instance_id
|
str
|
The instance id. |
required |
Source code in process_performance_indicators/indicators/time/instances.py
waiting_time(event_log: pd.DataFrame, instance_id: str) -> pd.Timedelta
¶
The elapsed time between the complete event of the activity instance that precedes the current activity instance, and the start event of the current activity instance.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
instance_id
|
str
|
The instance id. |
required |
Source code in process_performance_indicators/indicators/time/instances.py
process_performance_indicators.indicators.time.activities
¶
lead_time(event_log: pd.DataFrame, activity_name: str) -> pd.Timedelta
¶
The sum of total elapsed times of all instantiations of the activity.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
activity_name
|
str
|
The name of the activity. |
required |
Source code in process_performance_indicators/indicators/time/activities.py
service_and_lead_time_ratio(event_log: pd.DataFrame, activity_name: str) -> float
¶
The ratio between the sum of elapsed times between the start and complete events of all instantiations of the activity, and the sum of total elapsed times for all instantiations of the activity.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
activity_name
|
str
|
The name of the activity. |
required |
Source code in process_performance_indicators/indicators/time/activities.py
service_time(event_log: pd.DataFrame, activity_name: str) -> pd.Timedelta
¶
The sum of elapsed times between the start and complete events of all instantiations of the activity
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
activity_name
|
str
|
The name of the activity. |
required |
Source code in process_performance_indicators/indicators/time/activities.py
waiting_time(event_log: pd.DataFrame, activity_name: str) -> pd.Timedelta
¶
The sum of elapsed times between the complete events of activity instances that precede every instantiations of the activity, and the start event of each instantiation.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
activity_name
|
str
|
The name of the activity. |
required |
Source code in process_performance_indicators/indicators/time/activities.py
process_performance_indicators.indicators.time.cases
¶
active_time(event_log: pd.DataFrame, case_id: str) -> pd.Timedelta
¶
The difference between the total elapsed time of the case, and the sum of waiting times for every activity instance in the case where no other activity instance was being executed.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case ID. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
activity_count(event_log: pd.DataFrame, case_id: str) -> int
¶
The number of activities that occur in the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case ID. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
activity_instance_count(event_log: pd.DataFrame, case_id: str) -> int
¶
The number of times that any activity has been instantiated in the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case ID. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
automated_activity_count(event_log: pd.DataFrame, case_id: str, automated_activities: set[str]) -> int
¶
The number of automated activities that occur in the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case ID. |
required |
automated_activities
|
set[str]
|
The set of automated activities. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
automated_activity_instance_count(event_log: pd.DataFrame, case_id: str, automated_activities: set[str]) -> int
¶
The number of times that an automated activity is instantiated in the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
automated_activities
|
set[str]
|
The set of automated activities. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
automated_activity_service_time(event_log: pd.DataFrame, case_id: str, automated_activities: set[str]) -> pd.Timedelta
¶
The sum of elapsed times for all instantiations of automated activities in the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case ID. |
required |
automated_activities
|
set[str]
|
The set of automated activities. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
handover_count(event_log: pd.DataFrame, case_id: str) -> float
¶
The number of times that a human resource associated with an activity instance differs from the human resource associated with the preceding activity instance within the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case ID. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
idle_time(event_log: pd.DataFrame, case_id: str) -> pd.Timedelta
¶
The sum of waiting times for every activity instance in the case where no other activity instance was being executed.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
lead_time(event_log: pd.DataFrame, case_id: str) -> pd.Timedelta
¶
The total elapsed time between the earliest and latest timestamps in the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
lead_time_deviation_from_deadline(event_log: pd.DataFrame, case_id: str, deadline_margin: pd.Timedelta) -> pd.Timedelta
¶
The difference between the time that the case is expected to take, and the actual elapsed time between its earliest and latest timestamps. Negative values indicate that the case took less time than expected.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
deadline_margin
|
Timedelta
|
The margin of error for the deadline. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
lead_time_deviation_from_expectation(event_log: pd.DataFrame, case_id: str, expectation: pd.Timedelta) -> pd.Timedelta
¶
The absolute value of the difference between the time that the case is expected to take, and the actual elapsed time between its earliest and latest timestamps.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
expectation
|
Timedelta
|
The time delta the case is expected to take. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
lead_time_from_activity_a(event_log: pd.DataFrame, case_id: str, activity_a: str) -> pd.Timedelta | None
¶
The total elapsed time between the earliest instantiations of a specific activity, and the latest activity instance, in the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
activity_a
|
str
|
The specific activity name. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
lead_time_from_activity_a_to_b(event_log: pd.DataFrame, case_id: str, activity_a: str, activity_b: str) -> pd.Timedelta | None
¶
The total elapsed time between the earliest instantiations of a specific activity, and the earliest instantiations of another specific activity that precedes the other, in the case. Here "activity a precedes activity b".
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
activity_a
|
str
|
The specific activity name that precedes activity b. |
required |
activity_b
|
str
|
The specific activity name that follows activity a. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
lead_time_to_activity_a(event_log: pd.DataFrame, case_id: str, activity_a: str) -> pd.Timedelta | None
¶
The total elapsed time between the earliest activity instance, and the earliest instantiations of a specific activity, in the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
activity_a
|
str
|
The specific activity name. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
service_and_lead_time_ratio(event_log: pd.DataFrame, case_id: str) -> float
¶
The ratio between the sum of elapsed times between the start and complete events of all activity instance of the case, and the total elapsed time between the earliest and latest timestamps in the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
service_time(event_log: pd.DataFrame, case_id: str) -> pd.Timedelta
¶
The sum of elapsed times between the start and complete events of all activity instances of the case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
service_time_from_activity_a_to_b(event_log: pd.DataFrame, case_id: str, activity_a: str, activity_b: str, time_aggregation_mode: Literal['s', 'c', 'sc', 'w']) -> pd.Timedelta | None
¶
The sum elapsed times between the start and complete events of all activity instances of the case, which occur between the earliest instantiations of a specific activity, and the earliest instantiations of another specific activity that precedes the other. Here "activity a precedes activity b".
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
activity_a
|
str
|
The specific activity name that precedes activity b. |
required |
activity_b
|
str
|
The specific activity name that follows activity a. |
required |
time_aggregation_mode
|
Literal['s', 'c', 'sc', 'w']
|
The aggregation mode. "s": Considers activity instances that were started within the start and end activity instances. "c": Considers activity instances that were completed within the start and end activity instances. "sc": Considers activity instances that were either started or completed within the start and end activity instances. "w": Considers all activity instances that were active within the start and end activity instances. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
waiting_time(event_log: pd.DataFrame, case_id: str) -> pd.Timedelta
¶
The sum, for every activity instance in the case, of the elapsed time between the complete event of the activity instance that precedes it, and its start event.
Source code in process_performance_indicators/indicators/time/cases.py
waiting_time_from_activity_a_to_b(event_log: pd.DataFrame, case_id: str, activity_a: str, activity_b: str, time_aggregation_mode: Literal['s', 'c', 'sc', 'w']) -> pd.Timedelta | None
¶
The sum, for every activity instance in the case that occurs between the earliest instantiations of a specific activity, and the earliest instantiations of another specific activity that precedes the other, of the elapsed time between the complete event of the activity instance that precedes it, and its start event.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_id
|
str
|
The case id. |
required |
activity_a
|
str
|
The specific activity name that precedes activity b. |
required |
activity_b
|
str
|
The specific activity name that follows activity a. |
required |
time_aggregation_mode
|
Literal['s', 'c', 'sc', 'w']
|
The aggregation mode. "s": Considers activity instances that were started within the start and end activity instances. "c": Considers activity instances that were completed within the start and end activity instances. "sc": Considers activity instances that were either started or completed within the start and end activity instances. "w": Considers all activity instances that were active within the start and end activity instances. |
required |
Source code in process_performance_indicators/indicators/time/cases.py
process_performance_indicators.indicators.time.groups
¶
activity_count(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> int
¶
The number of activities that occur in the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
activity_instance_count(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> int
¶
The number of times that any activity has been instantiated in the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
automated_activity_count(event_log: pd.DataFrame, case_ids: list[str] | set[str], automated_activities: set[str]) -> int
¶
The number of automated activities that occur in the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
automated_activities
|
set[str]
|
The set of automated activities. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
automated_activity_instance_count(event_log: pd.DataFrame, case_ids: list[str] | set[str], automated_activities: set[str]) -> int
¶
The number of times that an automated activity is instantiated in the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
automated_activities
|
set[str]
|
The set of automated activities. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
automated_activity_service_time(event_log: pd.DataFrame, case_ids: list[str] | set[str], automated_activities: set[str]) -> pd.Timedelta
¶
The sum of elapsed times for all instantiations of automated activities in the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
automated_activities
|
set[str]
|
The set of automated activities. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
case_count_lead_time_ratio(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> float
¶
The ratio between the number of cases belonging to the group of cases, and the total elapsed time between the earliest and latest events in the group of cases. Returns cases per hour
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
case_count_where_lead_time_over_value(event_log: pd.DataFrame, case_ids: list[str] | set[str], lead_time_threshold: pd.Timedelta) -> int
¶
The number of cases belonging to the group of cases whose total elapsed time between the earliest and latest events is greater than the given value.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
lead_time_threshold
|
Timedelta
|
The threshold value as a time delta. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
case_percentage_where_lead_time_over_value(event_log: pd.DataFrame, case_ids: list[str] | set[str], lead_time_threshold: pd.Timedelta) -> float
¶
The percentage of cases belonging to the group of cases whose total elapsed time between the earliest and latest events is greater than the given value.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
lead_time_threshold
|
Timedelta
|
The threshold value as a time delta. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
case_percentage_with_missed_deadline(event_log: pd.DataFrame, case_ids: list[str] | set[str], deadline: pd.Timestamp) -> float
¶
The percentage of cases belonging to the group of cases whose latest event occurs after a given deadline.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
deadline
|
Timestamp
|
The deadline value as a timestamp. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_active_time(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> pd.Timedelta
¶
The difference between the total elapsed time of a case belonging to the group of cases, and the sum of waiting times for every activity instance in a case belonging to the group of cases where no other activity instance was being executed.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_activity_count(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> float
¶
The expected number of activities that occur in a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_activity_instance_count(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> float
¶
The expected number of times that any activity is instantiated in a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_automated_activity_count(event_log: pd.DataFrame, case_ids: list[str] | set[str], automated_activities: set[str]) -> float
¶
The expected number of automated activities that occur in a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
automated_activities
|
set[str]
|
The set of automated activities. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_automated_activity_instance_count(event_log: pd.DataFrame, case_ids: list[str] | set[str], automated_activities: set[str]) -> float
¶
The expected number of times that an automated activity is instantiated in a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
automated_activities
|
set[str]
|
The set of automated activities. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_automated_activity_service_time(event_log: pd.DataFrame, case_ids: list[str] | set[str], automated_activities: set[str]) -> pd.Timedelta
¶
The expected sum of elapsed times for all instantiations of automated activities in a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
automated_activities
|
set[str]
|
The set of automated activities. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_handover_count(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> float
¶
The expected number of times that a human resource associated with an activity instance differs from the human resource associated with the preceding activity instance within a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_idle_time(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> pd.Timedelta
¶
The expected sum of waiting times for every activity instance in a case belonging to the group of cases where no other activity instance was being executed.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_lead_time(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> pd.Timedelta
¶
The expected total elapsed time between the earliest and latest timestamps in a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_lead_time_deviation_from_deadline(event_log: pd.DataFrame, case_ids: list[str] | set[str], deadline_margin: pd.Timedelta) -> pd.Timedelta
¶
The difference between the time that a case in the group of cases is expected to take, and the actual elapsed time between its earliest and latest timestamps.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
deadline_margin
|
Timedelta
|
The margin of error for the deadline. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_lead_time_deviation_from_expectation(event_log: pd.DataFrame, case_ids: list[str] | set[str], expectation: pd.Timedelta) -> pd.Timedelta
¶
The absolute value of the difference between the time that a case in the group of cases is expected to take, and the actual elapsed time between its earliest and latest timestamps.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
expectation
|
Timedelta
|
The time delta the case is expected to take. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_lead_time_from_activity_a(event_log: pd.DataFrame, case_ids: list[str] | set[str], activity_a: str) -> pd.Timedelta
¶
The total elapsed time between the earliest instantiations of a specific activity, and the latest activity instance, that is expected for a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
activity_a
|
str
|
The specific activity name. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_lead_time_from_activity_a_to_b(event_log: pd.DataFrame, case_ids: list[str] | set[str], activity_a: str, activity_b: str) -> pd.Timedelta
¶
The total elapsed time between the earliest instantiations of a specific activity, and the earliest instantiations of another specific activity that precedes the other, that is expected for a case belonging to the group of cases. Here "activity a precedes activity b".
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
activity_a
|
str
|
The specific activity name that precedes activity b. |
required |
activity_b
|
str
|
The specific activity name that follows activity a. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_lead_time_to_activity_a(event_log: pd.DataFrame, case_ids: list[str] | set[str], activity_a: str) -> pd.Timedelta
¶
The total elapsed time between the earliest activity instance, and the earliest instantiations of a specific activity , that is expected for a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
activity_a
|
str
|
The specific activity name. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_service_and_lead_time_ratio(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> float
¶
The ratio between the sum of elapsed times between the start and complete events of all activity instances of the group of cases, and the expected total elapsed time between the earliest and latest timestamps in a case belonging to the group of cases
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_service_time(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> pd.Timedelta
¶
The expected sum of elapsed times between the start and complete events of all activity instances of a case belonging to the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_service_time_from_activity_a_to_b(event_log: pd.DataFrame, case_ids: list[str] | set[str], activity_a: str, activity_b: str, time_aggregation_mode: Literal['s', 'c', 'sc', 'w']) -> pd.Timedelta
¶
The expected sum of elapsed times between the start and complete events of all activity instances of every case in the group of cases, which occur between the earliest instantiations of a specific activity, and the earliest instantiations of another specific activity that precedes the other, in each case. Here "activity a precedes activity b".
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
activity_a
|
str
|
The specific activity name that precedes activity b. |
required |
activity_b
|
str
|
The specific activity name that follows activity a. |
required |
time_aggregation_mode
|
Literal['s', 'c', 'sc', 'w']
|
The aggregation mode. "s": Considers activity instances that were started within the start and end activity instances. "c": Considers activity instances that were completed within the start and end activity instances. "sc": Considers activity instances that were either started or completed within the start and end activity instances. "w": Considers all activity instances that were active within the start and end activity instances. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_waiting_time(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> pd.Timedelta
¶
The expected sum, for every activity instance in a case belonging to the group of cases, of the elapsed time between the complete event of the activity instance that precedes it, and its start event.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
expected_waiting_time_from_activity_a_to_b(event_log: pd.DataFrame, case_ids: list[str] | set[str], activity_a: str, activity_b: str, time_aggregation_mode: Literal['s', 'c', 'sc', 'w']) -> pd.Timedelta
¶
The expected sum, for every activity instance in a case belonging to the group of cases, that occurs between the earliest instantiations of a specific activity, and the earliest instantiations of another specific activity that precedes the other, of the elapsed time between the complete event of the activity instance that precedes it, and its start event.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
activity_a
|
str
|
The specific activity name that precedes activity b. |
required |
activity_b
|
str
|
The specific activity name that follows activity a. |
required |
time_aggregation_mode
|
Literal['s', 'c', 'sc', 'w']
|
The aggregation mode. "s": Considers activity instances that were started within the start and end activity instances. "c": Considers activity instances that were completed within the start and end activity instances. "sc": Considers activity instances that were either started or completed within the start and end activity instances. "w": Considers all activity instances that were active within the start and end activity instances. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
lead_time(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> pd.Timedelta
¶
The total elpased time between the earliest and latest eents in the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
lead_time_and_case_count_ratio(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> pd.Timedelta
¶
The ratio between the total elapsed time between the earliest and latest events in the group of cases, and the number of cases belonging to the group of cases. Returns hours per case.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
service_and_lead_time_ratio(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> float
¶
The ratio between the sum of elapsed times between the start and complete events of all activity instances of the group of cases, and the total elapsed time between the earliest and latest events in the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
service_time(event_log: pd.DataFrame, case_ids: list[str] | set[str]) -> pd.Timedelta
¶
The sum of elapsed times between the start and complete events of all activity instances of the group of cases.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case ids. |
required |
Source code in process_performance_indicators/indicators/time/groups.py
service_time_from_activity_a_to_b(event_log: pd.DataFrame, case_ids: list[str] | set[str], activity_a: str, activity_b: str, time_aggregation_mode: Literal['s', 'c', 'sc', 'w']) -> pd.Timedelta
¶
The sum of elapsed times between the start and complete events of all activity instances of every case in the group of cases, which occur between the earliest instantiations of a specific activity, and the earliest instantiations of another specific activity that precedes the other, in each case. Here "activity a precedes activity b".
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
event_log
|
DataFrame
|
The event log. |
required |
case_ids
|
list[str] | set[str]
|
The case IDs. |
required |
activity_a
|
str
|
The specific activity name that precedes activity b. |
required |
activity_b
|
str
|
The specific activity name that follows activity a. |
required |
time_aggregation_mode
|
Literal['s', 'c', 'sc', 'w']
|
The aggregation mode. "s": Considers activity instances that were started within the start and end activity instances. "c": Considers activity instances that were completed within the start and end activity instances. "sc": Considers activity instances that were either started or completed within the start and end activity instances. "w": Considers all activity instances that were active within the start and end activity instances. |
required |