Lag transforms on multiple unique_id values #192
elisevansartefact
started this conversation in
General
Replies: 1 comment 1 reply
-
|
Hey. We've thought of adding something to compute features aggregated at different levels as you suggest here but it's currently not possible. I'll create an issue for this. |
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.
-
If I want to use lags of y for each unique_id, and lag transformations such as rolling mean per unique_id, this is easy enough to do:
MLForecast(models = [MODELS], lags = [1, 2], lag_transforms={1: [(rolling_mean, 4)]})However, in order to include insights about the global trend, what if I want to include features which are transformations of the lags of every unique_id (not just one unique_id)?
For instance, what if I want to include the 4-week rolling mean of the sum of y for every unique_id? Or the mean of all the y_lag1 for each unique_id?
I suppose that this can be done via MLForecast.preprocess, however perhaps I am missing an easier way, and if not, perhaps a global_lag_transforms could be added in future as a parameter of MLForecast?
Beta Was this translation helpful? Give feedback.
All reactions