Fix timezone for US Eastern Time
parent
f37331f824
commit
2adfe8d81a
|
@ -11,8 +11,10 @@ DAY_SEGMENTS: &day_segments
|
|||
[daily, morning, afternoon, evening, night]
|
||||
|
||||
# Global timezone
|
||||
# Use codes from https://en.wikipedia.org/wiki/List_of_tz_database_time_zones
|
||||
# Double check your code, for example EST is not US Eastern Time.
|
||||
TIMEZONE: &timezone
|
||||
EST
|
||||
America/New_York
|
||||
|
||||
# Download data config
|
||||
DOWNLOAD_DATASET:
|
||||
|
|
|
@ -28,7 +28,7 @@ if(!is.null(timezone_periods)){
|
|||
timezone = as.character(timezone)) %>%
|
||||
rowwise() %>%
|
||||
mutate(utc_date_time = as.POSIXct(timestamp/1000, origin="1970-01-01", tz="UTC"),
|
||||
local_date_time = format(utc_date_time, tz = timezone, usetz = F))
|
||||
local_date_time = format(utc_date_time, tz = timezone, usetz = T))
|
||||
output <- split_local_date_time(output)
|
||||
write.csv(output, sensor_output)
|
||||
} else if(!is.null(fixed_timezone)){
|
||||
|
|
Loading…
Reference in New Issue