# Formula or Function to calculate a trend from historical data

Options

I am currently trying to calculate rate of leave taken of prior periods and compare it against corresponding months across different years. I was wondering if someone knows of a function or formula that works best for this?
Rate of leave taken = Accrued liability reversals(taking leave)/ Previous month(FINAL Existing hrs)

Source Module

Used the time module to map distinguishing dimension.

Target Module

Thank you!!!

• Options

You can use the POST function to push values from, let's say, FY23 months forward to FY24 and do the math further. Let me know if you're stuck with any specific calculation.

Happy to guide you there!

• Options

Thanks for quick response @Dikshant

• Options

@Dikshant I got stuck to this.

I'm calculating the Rate of Leave in the Target module

I should be getting
Nov'23 = -31,402/523,359 = -6%
Dec'23 = -58,533/532,120 = -11%

Here's the Source module

• Options

@ALC - Can you share the grid view and blueprint view for TME02: Time Map module and FY line item?

• Options

@ALC - Also try to change the format of the final line item as Percentage and decimal point as 3 places.

Possible issue can be the actual number comes to be 0.06 since the line item format is number but if you make decimal as 0 it will show 0.

Try it out!

• Options

Updated it to % at 3 decimal places. Still doesn't work.