I've been starting a new project related to process discovery. Therefore, I want to use pm4py to work with variants etc.
I found the following code in the documentation:
def import_csv(filename):
dataframe = pd.read_csv(filename, sep=',')
dataframe = pm4py.format_dataframe(dataframe, case_id='case:concept:name', activity_key='concept:name', timestamp_key='time:timestamp')
event_log = pm4py.convert_to_event_log(dataframe)
return event_log
and get this error:
Exception: case:concept:name column (case ID) is not in the dataframe!
My csv-file has the following columns:
case_id;activity;timestamp;costs;resource
I know that I need to declare the other columns somehow but I have no idea about the syntax. Can anyone help?
Thanks and kind regards Aaron