Open breadwall opened 1 month ago
THanks for raising the issue; I can reproduce.
I'll have to think about this a bit; I agree with your point that forecasts should only be required for the Top, but the implemented checks prevent that. Before simply bypassing these checks in this case I need to test a bit further if nothing else breaks.
It is an interesting quirk of the design. I noticed it too but did not really think too much into it because in my current use cases, which do not use this library yet, I generate forecasts for all levels. Of course, I can appreciate that in production, if you and your practitioner(s) decide on a particular single-level approach, there is no need to exhaustively forecast at every level or mess about with reshaping Y_hat_df
yourself, so thanks Olivier for looking into it! š
The forecasts for average_proportions
should be the same regardless of the forecasts of the lower levels though, so that is a worry if you fill them with $1$ and get strange results? Actually, come to think of it, we do not even need the in-sample values of the "middle" levels for this scenario, just the top and bottom levels.
What happened + What you expected to happen
Reconcile method TopDown with average_proportions appears to require forecasts for all hierarchy levels even though in TopDown you should just need the forecasts at the top and the historical values for all combinations. I tried filling in all missing hierarchies in the Y_hat_df with dummy values like 1, but the top-down forecasts are impacted.
Am I missing something?
Versions / Dependencies
hierarchical_forecast ~ 0.4.2
Reproduction script
Issue Severity
None