int <- new_interval(ymd("2001-01-01"), ymd("2002-01-01"))
# 2001-01-01 UTC--2002-01-01 UTC
int_shift(int, new_duration(days = 11))
# 2001-01-12 UTC--2002-01-12 UTC
int_shift(int, new_duration(hours = -1))
# 2000-12-31 23:00:00 UTC--2001-12-31 23:00:00 UTC
Run the code above in your browser using DataCamp Workspace