# Create a `aedseo_tsd` object from daily data
daily_tsd <- tsd(
observed = c(10, 15, 20, 18),
time = as.Date(
c("2023-01-01", "2023-01-02", "2023-01-03", "2023-01-04")
),
time_interval = "day"
)
# Create a `aedseo_tsd` object from weekly data
weekly_tsd <- tsd(
observed = c(100, 120, 130),
time = as.Date(
c("2023-01-01", "2023-01-08", "2023-01-15")
),
time_interval = "week"
)
# Create a `aedseo_tsd` object from monthly data
monthly_tsd <- tsd(
observed = c(500, 520, 540),
time = as.Date(
c("2023-01-01", "2023-02-01", "2023-03-01")
),
time_interval = "month"
)
Run the code above in your browser using DataLab