Understanding generate() function #128
nickcox896
started this conversation in
General
Replies: 1 comment 1 reply
-
|
Suppose you have monthly data, and you want to forecast the annual total over the next year. If you simulate future sample paths, and add them to get annual totals, you can estimate the forecast distribution easily. But you can't easily compute them (other than the mean) from the monthly forecast distributions. This is discussed in https://otexts.com/fpp3/aggregates.html The same general principle holds for anything you want to forecast that is a function of the variable you are modelling. Simulation makes it easy. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
If I understand correcty, the
generate()has the same logic with residual bootstrapping, apart from the factthat it samples the residuals from a normal distribution, instead of the past residuals
For example (https://fable.tidyverts.org/reference/generate.ARIMA.html)
from which we can simulate 10 future paths and then we can calculate the mean of the future simulated values for each forecast horizon.
If I am not wrong, this process can be done faster with
fable_fit |> forecast(h = 5, bootstrap = FALSE, times = 10,seed=1)My question is: what is the gain of using the former procedure compared with the latter
Logically, if I simulate a large number of future values, their mean for each horizon will be equal to those produced by latter approach
Unless I am missing something
Beta Was this translation helpful? Give feedback.
All reactions