This is a function used by decision_9.
decision_9
shift_interval(x)
x
a data frame containing variables start_date, stop_date and patid
start_date
stop_date
patid
A data frame with time intervals moved such that they no longer overlap