Process a single episode into a rectangular table with a timestamp column instead of the usual difftime since admission. The timestamp column corresponds to the exact timestamp of the event of interest. This is particularly useful for when you need to combine episodes into spells. Take care around times of clock change.

process_item_timestamp(df, var_name, metadata)

Arguments

df

a dataframe containing all episode information (It is unlikely that this will be accessed directly)

var_name

the CC-HIC codename for the current variable being processed

metadata

the CC-HIC metadata table