# Generate predictions of time series data
set.seed(123)
time_series <- generate_seasonal_data(
years = 1,
time_interval = "day"
)
# Apply `seasonal_onset` analysis
time_series_with_onset <- seasonal_onset(
tsd = time_series,
k = 7
)
# Predict observations for the next 7 time steps
predict(object = time_series_with_onset, n_step = 7)
Run the code above in your browser using DataLab