Writing of XES-files can be done using the function write_xes.

args(write_xes)
## function (eventlog, xesfile = file.choose(), case_attributes = NULL) 
## NULL

It minimally requires 2 arguments:

  • an event log object
  • a file name/path where to store the file (if not specified, as file system window will open to save the file)

Additionally, one can specify which of the variables in the event log should be regarded as case attributes by supplying a character vector of variable names to the case_attributes argument. If this argument is not specified, all the variables start with prefix CASE_ will be considered as case attributes.

eventdataR::patients

write_xes(patients, "patients.xes")