<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Calculating an attrition rate in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956485#M328668</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;check this thread :&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/docs/DOC-4252"&gt;Calculating rolling n-period totals, averages or other aggregations&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 12 Oct 2015 10:06:57 GMT</pubDate>
    <dc:creator>avinashelite</dc:creator>
    <dc:date>2015-10-12T10:06:57Z</dc:date>
    <item>
      <title>Calculating an attrition rate</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956484#M328667</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I would like to show a graph with the attrition rate for various departments.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I do have a table with the monthly headcounts dating back to April 2014 (our fiscal year starts in April).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I also have the number of employees that left the company on a monthly basis dating back to April 2014 in the following format:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="199"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD class="xl63" height="20" width="71"&gt;Period&lt;/TD&gt;&lt;TD class="xl63" width="64"&gt;Cost Centre&lt;/TD&gt;&lt;TD class="xl64" width="64"&gt;Leavers&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD align="right" class="xl65" height="20"&gt;30.04.2014&lt;/TD&gt;&lt;TD align="right"&gt;512&lt;/TD&gt;&lt;TD align="right"&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD align="right" class="xl65" height="20"&gt;31.05.2014&lt;/TD&gt;&lt;TD align="right"&gt;512&lt;/TD&gt;&lt;TD align="right"&gt;0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl65" height="20"&gt;…&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD align="right" class="xl65" height="20"&gt;31.08.2015&lt;/TD&gt;&lt;TD align="right"&gt;512&lt;/TD&gt;&lt;TD align="right"&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD align="right" class="xl65" height="20"&gt;30.09.2015&lt;/TD&gt;&lt;TD align="right"&gt;512&lt;/TD&gt;&lt;TD align="right"&gt;0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD align="right" class="xl66" height="20"&gt;30.04.2014&lt;/TD&gt;&lt;TD align="right" class="xl67"&gt;200&lt;/TD&gt;&lt;TD align="right" class="xl68"&gt;0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD align="right" class="xl65" height="20"&gt;31.05.2014&lt;/TD&gt;&lt;TD align="right"&gt;200&lt;/TD&gt;&lt;TD align="right" class="xl69"&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl65" height="20"&gt;…&lt;/TD&gt;&lt;TD align="right"&gt;200&lt;/TD&gt;&lt;TD align="right" class="xl69"&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD align="right" class="xl65" height="20"&gt;31.08.2015&lt;/TD&gt;&lt;TD align="right"&gt;200&lt;/TD&gt;&lt;TD align="right" class="xl69"&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD align="right" class="xl65" height="20"&gt;30.09.2015&lt;/TD&gt;&lt;TD align="right"&gt;200&lt;/TD&gt;&lt;TD align="right" class="xl69"&gt;&lt;P&gt;1&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;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:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SUM of all leavers between May 2014 and April 2015 for Department X&lt;/P&gt;&lt;P&gt;------------------------------------------------------------------------------------------------------&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; = Annual Attrition Rate in %&lt;/P&gt;&lt;P&gt;Average of Headcount between May 2014 and April 2015 for Department X&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;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.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Furthermore, if I then try to divide the Leavers / AvgEmployees, I get values that I cannot reconcile.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/101710_pastedImage_3.png" style="max-width: 1200px; max-height: 900px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/101718_pastedImage_5.png" style="max-width: 1200px; max-height: 900px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;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.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for any hints.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Oct 2015 09:33:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956484#M328667</guid>
      <dc:creator />
      <dc:date>2015-10-12T09:33:41Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating an attrition rate</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956485#M328668</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;check this thread :&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.qlik.com/docs/DOC-4252"&gt;Calculating rolling n-period totals, averages or other aggregations&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 12 Oct 2015 10:06:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956485#M328668</guid>
      <dc:creator>avinashelite</dc:creator>
      <dc:date>2015-10-12T10:06:57Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating an attrition rate</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956486#M328669</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for your hint. I didn't see that post yet.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was hoping that the &lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;sum&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;aggr&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;rangesum&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;above&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;sum&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;(Sales),0,12) ),&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: maroon;"&gt;Month&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff; font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;)) &lt;/SPAN&gt;&lt;SPAN style="color: black; background-color: #ffffff; font-family: arial,helvetica,sans-serif;"&gt;would do the trick, but it looks like that is not helping.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: arial,helvetica,sans-serif; color: black;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: arial,helvetica,sans-serif; color: black;"&gt;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.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: arial,helvetica,sans-serif; color: black;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff; font-family: arial,helvetica,sans-serif; color: black;"&gt;It's kinda disappointing that there isn't a simpler solution to such a common problem&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 13 Oct 2015 06:53:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956486#M328669</guid>
      <dc:creator />
      <dc:date>2015-10-13T06:53:36Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating an attrition rate</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956487#M328670</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try like this once :&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;aggr&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;rangesum&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;( &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;above&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;(&lt;SPAN style="color: #0000ff; font-family: verdana, geneva; font-size: 13.3333px;"&gt;total &lt;/SPAN&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: blue;"&gt;sum&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;(&lt;SPAN style="color: #000000; font-family: verdana, geneva; font-size: 13.3333px;"&gt;{&amp;lt;Month=&amp;gt;}&lt;/SPAN&gt;Sales),0,12) ),&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: maroon;"&gt;Month&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt; font-family: 'Courier New'; color: black;"&gt;))&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 13 Oct 2015 07:58:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956487#M328670</guid>
      <dc:creator>avinashelite</dc:creator>
      <dc:date>2015-10-13T07:58:35Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating an attrition rate</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956488#M328671</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Avinash&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had to try a bit more and your formula did the job:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That's what I have now and it calculates it correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sum(Aggr(RangeSum(Above(Total Sum({$&amp;lt;Month=&amp;gt;} Leavers),0,12)), Month))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much!!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Oct 2015 06:11:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956488#M328671</guid>
      <dc:creator />
      <dc:date>2015-10-15T06:11:39Z</dc:date>
    </item>
    <item>
      <title>Re: Calculating an attrition rate</title>
      <link>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956489#M328672</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Matthias,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your always welcome with questions.. Happy learning &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Oct 2015 05:36:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calculating-an-attrition-rate/m-p/956489#M328672</guid>
      <dc:creator>avinashelite</dc:creator>
      <dc:date>2015-10-16T05:36:42Z</dc:date>
    </item>
  </channel>
</rss>

