Closed
Description
Hi! Thanks for this amazing library.
While reproducing the example notebook AustralianPrisonPopulation.ipynb, I noticed the comment: "Since the hierarchy structure is not strict, we can't use methods such as TopDown or MiddleOut."
This raises a couple of questions:
- Why is that? Is there a mathematical reason preventing their use? I’d particularly appreciate a conceptual clarification on this point.
- Surprisingly,
TopDown(method="forecast_proportions")
can be used in the example. Why is forecast_proportions compatible with non-strict hierarchical structures, while average_proportions and proportion_averages are not? - Additionally, none of the three MiddleOut proportions variants seem to work. However, if TopDown method with forecast_proportions is allowed, why isn’t MiddleOut with forecast_proportions also supported?
Here’s the list of reconcilers I tested using the same dataset from the AustralianPrisonPopulation example notebook:
reconcilers = [
# Used in the example notebook
BottomUp(),
MinTrace(method='mint_shrink'),
# Added by me for testing
TopDown(method="forecast_proportions"), # Works
# The following raise ValueError: "Top-down reconciliation requires strictly hierarchical structures."
# TopDown(method="average_proportions"),
# TopDown(method="proportion_averages"),
# The following raise ValueError: "Middle out reconciliation requires strictly hierarchical structures."
# MiddleOut(middle_level="Country/Legal", top_down_method="forecast_proportions"),
# MiddleOut(middle_level="Country/Legal", top_down_method="average_proportions"),
# MiddleOut(middle_level="Country/Legal", top_down_method="proportion_averages"),
]
I’d really appreciate any clarification on this!
Thanks in advance.