Time arithmetic

# When in standard format, a string does not need a format spefication in order
# to be translatable
t0 <- as.POSIXct("2020-02-01 00:00",tz="GMT")
t0
[1] "2020-02-01 GMT"
# Adding 3600 seconds means adding an hour:
t0 + 3600
[1] "2020-02-01 01:00:00 GMT"
# Subtracting seconds may also change the date:
t0 - 1
[1] "2020-01-31 23:59:59 GMT"
# A day is 24 times 3600 seconds
day <- 24*3600
t0 + day
[1] "2020-02-02 GMT"