<?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: Aggr in a Chart in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Aggr-in-a-Chart/m-p/1233743#M517985</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So why is 100% wrong? Are we basically trying to limit actual calls to expected for each physician? So Dr. Smith is 2/2, Dr. Jones is 2/2, Dr. Bob is 1/3, and Dr. Sue is 2/2? So the total should be 7/9 = 78%?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Maybe this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;sum(aggr(rangemin(sum(ACTUAL_CALLS),sum(EXPECTED_CALL)),PHYS_ID))/sum(EXPECTED_CALL)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 10 Nov 2016 17:26:22 GMT</pubDate>
    <dc:creator>johnw</dc:creator>
    <dc:date>2016-11-10T17:26:22Z</dc:date>
    <item>
      <title>Aggr in a Chart</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-in-a-Chart/m-p/1233742#M517984</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Been awhile since I've been developing in Qlik and have been getting hung up on this expression. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm trying to show a line chart with the total percentage of Actual to Expected calls. If the Actual Calls is greater than the Expected, we just take the expected/expected so basically 1. But I want to show the aggregated percentage of all Physicians at the week end. See below. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF(ACTUAL_CALLS&amp;gt;EXPECTED_CALL, Aggr(SUM(EXPECTED_CALL)/SUM(EXPECTED_CALL),PHYS_ID), AGGR(SUM(ACTUAL_CALLS)/SUM(EXPECTED_CALL),PHYS_ID))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Gives me No data in the chart below. &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IF(ACTUAL_CALLS&amp;gt;EXPECTED_CALL, SUM(EXPECTED_CALL)/SUM(EXPECTED_CALL), SUM(ACTUAL_CALLS)/SUM(EXPECTED_CALL))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Gives me the total below but it's not given me the aggregated total by PHYS ID.&amp;nbsp; 7/29 shows 100% but if you look in the source data that's not the case. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="test.png" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/143551_test.png" style="height: 233px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="test2.png" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/143570_test2.png" style="height: auto;" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Nov 2016 17:13:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-in-a-Chart/m-p/1233742#M517984</guid>
      <dc:creator />
      <dc:date>2016-11-10T17:13:49Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr in a Chart</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-in-a-Chart/m-p/1233743#M517985</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;So why is 100% wrong? Are we basically trying to limit actual calls to expected for each physician? So Dr. Smith is 2/2, Dr. Jones is 2/2, Dr. Bob is 1/3, and Dr. Sue is 2/2? So the total should be 7/9 = 78%?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Maybe this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;sum(aggr(rangemin(sum(ACTUAL_CALLS),sum(EXPECTED_CALL)),PHYS_ID))/sum(EXPECTED_CALL)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Nov 2016 17:26:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-in-a-Chart/m-p/1233743#M517985</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2016-11-10T17:26:22Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr in a Chart</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-in-a-Chart/m-p/1233744#M517986</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Or if we'll only ever have one row per physician and week:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;sum(aggr(rangemin(ACTUAL_CALLS,EXPECTED_CALL),PHYS_ID))/sum(EXPECTED_CALL)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or if you need to do this in a chart where week is not a dimension:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;sum(aggr(rangemin(ACTUAL_CALLS,EXPECTED_CALL),PHYS_ID,WK_ENDING))/sum(EXPECTED_CALL)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Nov 2016 17:30:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-in-a-Chart/m-p/1233744#M517986</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2016-11-10T17:30:51Z</dc:date>
    </item>
    <item>
      <title>Re: Aggr in a Chart</title>
      <link>https://community.qlik.com/t5/QlikView/Aggr-in-a-Chart/m-p/1233745#M517987</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the help John. I am trying to show the total (i.e 7/9 78%) and it seems as if last expression worked in the chart to display across the different weeks. Thanks again.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 12px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d; background-color: #f2f2f2;"&gt;Or if you need to do this in a chart where week is not a dimension:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding: 0 0 0 30px; font-size: 12px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d; background-color: #f2f2f2;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'courier new', courier;"&gt;sum(aggr(rangemin(ACTUAL_CALLS,EXPECTED_CALL),PHYS_ID,WK_ENDING))/sum(EXPECTED_CALL)&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Nov 2016 17:38:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Aggr-in-a-Chart/m-p/1233745#M517987</guid>
      <dc:creator />
      <dc:date>2016-11-10T17:38:00Z</dc:date>
    </item>
  </channel>
</rss>

