<?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: Sum averages for one dimension in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Sum-averages-for-one-dimension/m-p/1223176#M621202</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Andrey for that input.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In fact that means I already had the correct formula, however because I worked with an additional dimension (which I did not include here as I thought it was not relevant) the result did not look correct to me. Thanks to your confirmation I looked at it once again and figured out how I had to include the second dimension:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;=Sum(Aggr(Avg ( Audience), Country, Year))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Cheers,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Benedikt&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 20 Feb 2017 19:47:39 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2017-02-20T19:47:39Z</dc:date>
    <item>
      <title>Sum averages for one dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-averages-for-one-dimension/m-p/1223174#M621200</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am looking for the correct formula to create a sum of averages for a certain dimension in my datasheet.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My datasheet is organized like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="1" class="jiveBorder" style="border: 1px solid rgb(0, 0, 0); width: 100%;"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Country&lt;/STRONG&gt;&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;Channel&lt;/TH&gt;&lt;TH style="text-align: center; background-color: #6690bc; color: #ffffff; padding: 2px;" valign="middle"&gt;&lt;STRONG&gt;Audience (individuals)&lt;/STRONG&gt;&lt;/TH&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;Albania&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Channel A&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;&lt;P&gt;1000&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;Albania&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Channel B&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;2000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD style="padding: 2px;"&gt;Brazil&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;Channel C&lt;/TD&gt;&lt;TD style="padding: 2px;"&gt;3000&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;Brazil&lt;/TD&gt;&lt;TD&gt;Channel D&lt;/TD&gt;&lt;TD&gt;4000&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I now need to create an average audience per country which needs to be summed up afterwards --&amp;gt; For this test case the result should say 5000.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So far I have tried the following options, but none of them works:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=sum(aggr(avg([Audience (Individuals)]), country))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=sum(aggr(sum([Audience (Individuals)])/count([Audience (Individuals)]) , Country))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In a second step it would be perfect if the formula could leave out those lines of the calculation, that do not have an entry for "Audience (individuals)".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any suggestions?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;BN&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 19 Feb 2017 20:13:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-averages-for-one-dimension/m-p/1223174#M621200</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-02-19T20:13:37Z</dc:date>
    </item>
    <item>
      <title>Re: Sum averages for one dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-averages-for-one-dimension/m-p/1223175#M621201</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Benedikt,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="2.jpg" class="jive-image image-2" src="https://community.qlik.com/legacyfs/online/153706_2.jpg" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=Sum(Aggr(Avg ( Audience), Country))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Result&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="1.jpg" class="jive-image image-1" src="https://community.qlik.com/legacyfs/online/153705_1.jpg" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Andrey&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2017 09:27:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-averages-for-one-dimension/m-p/1223175#M621201</guid>
      <dc:creator>ahaahaaha</dc:creator>
      <dc:date>2017-02-20T09:27:56Z</dc:date>
    </item>
    <item>
      <title>Re: Sum averages for one dimension</title>
      <link>https://community.qlik.com/t5/QlikView/Sum-averages-for-one-dimension/m-p/1223176#M621202</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Andrey for that input.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In fact that means I already had the correct formula, however because I worked with an additional dimension (which I did not include here as I thought it was not relevant) the result did not look correct to me. Thanks to your confirmation I looked at it once again and figured out how I had to include the second dimension:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;=Sum(Aggr(Avg ( Audience), Country, Year))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Cheers,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Benedikt&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2017 19:47:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Sum-averages-for-one-dimension/m-p/1223176#M621202</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-02-20T19:47:39Z</dc:date>
    </item>
  </channel>
</rss>

