Hello everybody!
I've come across a problem with making accurate calculations for a line item in currency/unit for previous year.
My model has system version called "current" which has 5 years (2019-2023).
Time options: months, quarter, ytd, FY.
I'm making a module that is based on line item subset (included are: Volume in ton, Absolute cost Amount, cost per ton), plants of production, time (months), no model's versions.
Line items stand for: current year, previous year, budget and their differences.
Something like:

I have line item 'collect' that is used as data-bank for other line items (for instance, RoFC stands for current system versions).
I retrieve data per line item as: collect[select: versions.current].
For previous year (FY 19) I use function POST (RoFC,12).
It works fine until it comes to summing data at plant level (all production plants) and for Q, YTD and FY for cost/t line items (even at the level of a particular plant).
Such functions as POST, LAG, OFFSET, MOVINGSUM do not allow to have summary method set as Formula.
In that case what will be correct way to do this calculations for previous year with proper summing for Time and Plants?
Thank you.