library(MazamaCoreUtils)
dateSequence("2019-11-01", "2019-11-08", timezone = "America/Los_Angeles")
dateSequence("2019-11-01", "2019-11-07", timezone = "America/Los_Angeles",
ceilingEnd = TRUE)
# Observe the handling of daylight savings
datetime <- dateSequence("2019-11-01", "2019-11-08",
timezone = "America/Los_Angeles")
datetime
lubridate::with_tz(datetime, "UTC")
# Passing in POSIXct values preserves the instant in time before flooring --
# midnight Tokyo time is the day before in UTC
jst <- dateSequence(20190307, 20190315, timezone = "Asia/Tokyo")
jst
dateSequence(jst[1], jst[7], timezone = "UTC")
Run the code above in your browser using DataLab