Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Calculating an attrition rate

I would like to show a graph with the attrition rate for various departments.

I do have a table with the monthly headcounts dating back to April 2014 (our fiscal year starts in April).

I also have the number of employees that left the company on a monthly basis dating back to April 2014 in the following format:

  

PeriodCost CentreLeavers
30.04.20145122
31.05.20145120
31.08.20155121
30.09.20155120
30.04.20142000
31.05.20142002
2001
31.08.20152003
30.09.2015200

1

The chart should only start showing the values as per April 2015 and I want to have an annualized attrition rate. So for April 2015 the attrition rate should be calculated as follows:

SUM of all leavers between May 2014 and April 2015 for Department X

------------------------------------------------------------------------------------------------------       = Annual Attrition Rate in %

Average of Headcount between May 2014 and April 2015 for Department X

I managed to create a straight table that shows the Average Crew and Cumulative Leavers using the Accumulation of 12 Steps Back in the Expression. But this only works, if I also display the values for 2014. Yet, I do not want to show 2014 values, as these are not for a 12 month basis and therefore not comparable.

Furthermore, if I then try to divide the Leavers / AvgEmployees, I get values that I cannot reconcile.

I'm unsure if it would be easier to do an accumulation during the loading script, or if it would be possible to calculate this using a set analysis.

Thanks for any hints.

1 Solution

Accepted Solutions
avinashelite

Try like this once :

sum( aggr( rangesum( above(total sum({<Month=>}Sales),0,12) ),Month))

View solution in original post

5 Replies
Not applicable
Author

Thanks for your hint. I didn't see that post yet.

I was hoping that the sum( aggr( rangesum( above( sum(Sales),0,12) ),Month)) would do the trick, but it looks like that is not helping.


I'm a bit reluctant to go for the AsOf table, as it seems to be complicating things quite a bit if you don't have just a simple data model like in your example.


It's kinda disappointing that there isn't a simpler solution to such a common problem

avinashelite

Try like this once :

sum( aggr( rangesum( above(total sum({<Month=>}Sales),0,12) ),Month))

Not applicable
Author

Hi Avinash

I had to try a bit more and your formula did the job:

That's what I have now and it calculates it correctly.

Sum(Aggr(RangeSum(Above(Total Sum({$<Month=>} Leavers),0,12)), Month))

Thank you very much!!

avinashelite

Hi Matthias,

Your always welcome with questions.. Happy learning