library(tsibble)
pedestrian %>%
# Currently only supports daily data
index_by(Date) %>%
dplyr::summarise(Count = sum(Count)) %>%
# Compute weekly aggregates
fabletools:::aggregate_index("1 week", Count = sum(Count))
Run the code above in your browser using DataLab