<?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: result of avg() dimension differs from expectation in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533137#M438906</link>
    <description>&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;this solution works well when I have only one value in the field PAGA_GA_ID selected.&lt;/P&gt;&lt;P&gt;However when I select more than one it calculates an average of all visible though I need an average for each field PAGA_GA_ID.&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="qlik3.jpg" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/4212i558765675800269F/image-size/large?v=v2&amp;amp;px=999" role="button" title="qlik3.jpg" alt="qlik3.jpg" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;I tried to amend the aggregation but I failed until now.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;=num(&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;Avg({&amp;lt;PCHA_PUBL={1},PCHA_CHAR_ID = {"=Count(DISTINCT PCHA_CHAR_ID=PCGA_CHAR_ID) &amp;gt; 1"}&amp;gt;} &lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;TOTAL Aggr(&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;Count({$&amp;lt;PCHA_VALUE_GB -= {'-'}&amp;gt;} PBGA_BG_NO)&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;/&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;Max(Aggr(NODISTINCT Count(PBGA_BG_NO), PAGA_GA_ID))&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;, PCHA_CHAR_ID, PAGA_GA_ID)),'##0 %')&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;Thank you in advance.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;May you help how I have to adjust the expression to have an average for each PAGA_GA_ID:&lt;/P&gt;</description>
    <pubDate>Tue, 22 Jan 2019 10:43:06 GMT</pubDate>
    <dc:creator>citizenk</dc:creator>
    <dc:date>2019-01-22T10:43:06Z</dc:date>
    <item>
      <title>result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532189#M438836</link>
      <description>&lt;P&gt;Dear all,&lt;/P&gt;&lt;P&gt;I have difficulties with the AVG() function.&lt;BR /&gt;&lt;BR /&gt;I created an expression which gives me a coverage&lt;/P&gt;&lt;P&gt;Expression "coverage":&lt;/P&gt;&lt;P&gt;&lt;FONT color="#008000"&gt;&lt;STRONG&gt;Count({$&amp;lt;PCHA_VALUE_GB-={'-'}&amp;gt;}PBGA_BG_NO) / max(aggr(nodistinct Count(PBGA_BG_NO), PAGA_GA_ID))&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Now I want to calculate the average of this expression as a dimension but the result differs from the total average I can set in the presentation tab:&lt;BR /&gt;&lt;BR /&gt;Dimension "average"&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;avg(total aggr(&lt;/FONT&gt;&lt;FONT color="#008000"&gt;Count({$&amp;lt;PCHA_VALUE_GB-={'-'}&amp;gt;}PBGA_BG_NO) / max(aggr(nodistinct Count(PBGA_BG_NO), PAGA_GA_ID))&lt;/FONT&gt;&lt;FONT color="#FF0000"&gt;, PCHA_CHAR_ID, PAGA_GA_ID))&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;My expectation is that I receive 0,43. Instead I receive 0,3000811.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="chart" style="width: 572px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/4051i3B184D203223B36A/image-size/large?v=v2&amp;amp;px=999" role="button" title="avg.jpg" alt="chart" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;chart&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Any help is appreciated.&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 04:43:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532189#M438836</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2024-11-16T04:43:01Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532201#M438839</link>
      <description>&lt;P&gt;I think you have a third dimension (Characterstic) which you have not added to your Aggr() function. Can you add that and see if that resolves your issue?&lt;/P&gt;</description>
      <pubDate>Fri, 18 Jan 2019 14:46:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532201#M438839</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-01-18T14:46:03Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532207#M438840</link>
      <description>&lt;P&gt;This is a calculated dimension, however when I include the source of this dimension, no changes are visible:&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="avg1.jpg" style="width: 696px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/4055i6CCDC098DEE2FCFC/image-size/large?v=v2&amp;amp;px=999" role="button" title="avg1.jpg" alt="avg1.jpg" /&gt;&lt;/span&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;avg(total aggr&lt;/FONT&gt;&lt;FONT color="#008000"&gt;(Count({$&amp;lt;PCHA_VALUE_GB-={'-'}&amp;gt;}PBGA_BG_NO) / max(aggr(nodistinct Count(PBGA_BG_NO), PAGA_GA_ID))&lt;/FONT&gt;, &lt;FONT color="#FF0000"&gt;PCHA_CHAR_ID, PAGA_GA_ID,&lt;/FONT&gt; &lt;FONT color="#FF9900"&gt;PCHA_CHAR_GB&lt;/FONT&gt;&lt;FONT color="#FF0000"&gt;))&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 18 Jan 2019 14:55:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532207#M438840</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2019-01-18T14:55:22Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532213#M438841</link>
      <description>&lt;P&gt;Can you try this&lt;/P&gt;&lt;PRE&gt;Avg({&amp;lt;PCHA_PUBL = {1}&amp;gt;} TOTAL Aggr(

Count({$&amp;lt;PCHA_VALUE_GB -= {'-'}, PCHA_PUBL = {1}&amp;gt;} PBGA_BG_NO)/
Max({&amp;lt;PCHA_PUBL = {1}&amp;gt;}Aggr(NODISTINCT Count({&amp;lt;PCHA_PUBL = {1}&amp;gt;}PBGA_BG_NO), PAGA_GA_ID))

, PCHA_CHAR_ID, PAGA_GA_ID, PCHA_CHAR_GB))&lt;/PRE&gt;&lt;P&gt;Or this&lt;/P&gt;&lt;PRE&gt;Avg({&amp;lt;PCHA_PUBL = {1}&amp;gt;} TOTAL Aggr(

Count({$&amp;lt;PCHA_VALUE_GB -= {'-'}&amp;gt;} PBGA_BG_NO)/
Max(Aggr(NODISTINCT Count(PBGA_BG_NO), PAGA_GA_ID))

, PCHA_CHAR_ID, PAGA_GA_ID, PCHA_CHAR_GB))&lt;/PRE&gt;</description>
      <pubDate>Fri, 18 Jan 2019 14:59:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532213#M438841</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-01-18T14:59:15Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532217#M438842</link>
      <description>Thank you. Both work perfectly.</description>
      <pubDate>Fri, 18 Jan 2019 15:01:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1532217#M438842</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2019-01-18T15:01:35Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533137#M438906</link>
      <description>&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;this solution works well when I have only one value in the field PAGA_GA_ID selected.&lt;/P&gt;&lt;P&gt;However when I select more than one it calculates an average of all visible though I need an average for each field PAGA_GA_ID.&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="qlik3.jpg" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/4212i558765675800269F/image-size/large?v=v2&amp;amp;px=999" role="button" title="qlik3.jpg" alt="qlik3.jpg" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;I tried to amend the aggregation but I failed until now.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;=num(&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;Avg({&amp;lt;PCHA_PUBL={1},PCHA_CHAR_ID = {"=Count(DISTINCT PCHA_CHAR_ID=PCGA_CHAR_ID) &amp;gt; 1"}&amp;gt;} &lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;TOTAL Aggr(&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;Count({$&amp;lt;PCHA_VALUE_GB -= {'-'}&amp;gt;} PBGA_BG_NO)&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;/&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;Max(Aggr(NODISTINCT Count(PBGA_BG_NO), PAGA_GA_ID))&lt;/FONT&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;, PCHA_CHAR_ID, PAGA_GA_ID)),'##0 %')&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;Thank you in advance.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;May you help how I have to adjust the expression to have an average for each PAGA_GA_ID:&lt;/P&gt;</description>
      <pubDate>Tue, 22 Jan 2019 10:43:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533137#M438906</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2019-01-22T10:43:06Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533214#M438915</link>
      <description>&lt;P&gt;Try one of these&lt;/P&gt;&lt;PRE&gt;Avg({&amp;lt;PCHA_PUBL = {1}&amp;gt;} TOTAL &lt;FONT color="#FF0000"&gt;&amp;lt;PAGA_GA_ID&amp;gt;&lt;/FONT&gt; Aggr(

Count({$&amp;lt;PCHA_VALUE_GB -= {'-'}, PCHA_PUBL = {1}&amp;gt;} PBGA_BG_NO)/
Max({&amp;lt;PCHA_PUBL = {1}&amp;gt;}Aggr(NODISTINCT Count({&amp;lt;PCHA_PUBL = {1}&amp;gt;}PBGA_BG_NO), PAGA_GA_ID))

, PCHA_CHAR_ID, PAGA_GA_ID, PCHA_CHAR_GB))&lt;/PRE&gt;&lt;P&gt;Or this&lt;/P&gt;&lt;PRE&gt;Avg({&amp;lt;PCHA_PUBL = {1}&amp;gt;} TOTAL&lt;FONT color="#FF0000"&gt; &amp;lt;PAGA_GA_ID&amp;gt;&lt;/FONT&gt; Aggr(

Count({$&amp;lt;PCHA_VALUE_GB -= {'-'}&amp;gt;} PBGA_BG_NO)/
Max(Aggr(NODISTINCT Count(PBGA_BG_NO), PAGA_GA_ID))

, PCHA_CHAR_ID, PAGA_GA_ID, PCHA_CHAR_GB))&lt;/PRE&gt;</description>
      <pubDate>Tue, 22 Jan 2019 12:09:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533214#M438915</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-01-22T12:09:48Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533219#M438916</link>
      <description>Sadly, they return an "//Error in calculated dimension" though the expression is considered as OK.</description>
      <pubDate>Tue, 22 Jan 2019 12:15:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533219#M438916</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2019-01-22T12:15:57Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533231#M438917</link>
      <description>&lt;P&gt;When did you switch from using an expression to a calculated dimension? or were you always using this as a calculated dimension?&lt;/P&gt;</description>
      <pubDate>Tue, 22 Jan 2019 12:24:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533231#M438917</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-01-22T12:24:34Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533233#M438919</link>
      <description>&lt;P&gt;Give this a try&lt;/P&gt;&lt;PRE&gt;&lt;FONT color="#FF0000"&gt;Aggr(&lt;/FONT&gt;
Avg({&amp;lt;PCHA_PUBL = {1}&amp;gt;} TOTAL Aggr(

Count({$&amp;lt;PCHA_VALUE_GB -= {'-'}, PCHA_PUBL = {1}&amp;gt;} PBGA_BG_NO)/
Max({&amp;lt;PCHA_PUBL = {1}&amp;gt;}Aggr(NODISTINCT Count({&amp;lt;PCHA_PUBL = {1}&amp;gt;}PBGA_BG_NO), PAGA_GA_ID))

, PCHA_CHAR_ID, PAGA_GA_ID, PCHA_CHAR_GB))
&lt;FONT color="#FF0000"&gt;, PAGA_GA_ID)&lt;/FONT&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 22 Jan 2019 12:25:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533233#M438919</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-01-22T12:25:32Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533242#M438921</link>
      <description>This gives the same result for both PAGA_GA_ID like in the picture above while it should differ per PAGA_GA_ID.</description>
      <pubDate>Tue, 22 Jan 2019 12:34:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533242#M438921</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2019-01-22T12:34:37Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533245#M438923</link>
      <description>&lt;P&gt;Yes it was my bad once again.... remove TOTAL qualifier...&lt;/P&gt;&lt;PRE&gt;Aggr(
Avg({&amp;lt;PCHA_PUBL = {1}&amp;gt;} &lt;STRIKE&gt;&lt;FONT color="#FF0000"&gt;TOTAL&lt;/FONT&gt; &lt;/STRIKE&gt;Aggr(

Count({$&amp;lt;PCHA_VALUE_GB -= {'-'}, PCHA_PUBL = {1}&amp;gt;} PBGA_BG_NO)/
Max({&amp;lt;PCHA_PUBL = {1}&amp;gt;}Aggr(NODISTINCT Count({&amp;lt;PCHA_PUBL = {1}&amp;gt;}PBGA_BG_NO), PAGA_GA_ID))

, PCHA_CHAR_ID, PAGA_GA_ID, PCHA_CHAR_GB))
, PAGA_GA_ID)&lt;/PRE&gt;</description>
      <pubDate>Tue, 22 Jan 2019 12:36:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533245#M438923</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-01-22T12:36:46Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533251#M438924</link>
      <description>Thanks a lot, that does the job!&lt;BR /&gt;I hope I can utilise this for all the according calculations I need.</description>
      <pubDate>Tue, 22 Jan 2019 12:45:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1533251#M438924</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2019-01-22T12:45:49Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1534229#M439020</link>
      <description>&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;My aplogies for coming up with this topic again but I encounter another issue with this since the values differ.&lt;/P&gt;&lt;P&gt;Having one PAGA_GA_ID selected everything is OK, but having multiple PAGA_GA_ID selected, the values differ and I can't even reproduce how they have been calculated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="avg3.jpg" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/4370i1D210EE46D4712C3/image-size/large?v=v2&amp;amp;px=999" role="button" title="avg3.jpg" alt="avg3.jpg" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="avg4.jpg" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/4369i0F4F1BAD984DF47F/image-size/large?v=v2&amp;amp;px=999" role="button" title="avg4.jpg" alt="avg4.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;My efforts to alter the most outer aggregation in terms of fields to be considered failed and I can't find anything helpful in the community board.&lt;BR /&gt;&lt;BR /&gt;May you assist me once more?&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Thu, 24 Jan 2019 06:30:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1534229#M439020</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2019-01-24T06:30:34Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1534424#M439037</link>
      <description>&lt;P&gt;It would be easier to help if you are able to share your qvw file.&lt;/P&gt;</description>
      <pubDate>Thu, 24 Jan 2019 12:13:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1534424#M439037</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-01-24T12:13:56Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1534633#M439065</link>
      <description>&lt;P&gt;Hi Sunny,&lt;/P&gt;&lt;P&gt;to share the file is rather difficult (company data) and I have no idea how I could break it down best possible. Maybe a further explanation helps:&lt;/P&gt;&lt;P&gt;In this chart I calculate a coverage and my focus is the coverage proposed ch..(..aracteristics)&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="avg5.jpg" style="width: 999px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/4424iCA34E3A66A3A5ACF/image-size/large?v=v2&amp;amp;px=999" role="button" title="avg5.jpg" alt="avg5.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I populated the dimension "coverage all characteristics" successully with the expression in the picture (again here):&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;=num(Aggr(&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;Avg({&amp;lt;PCHA_PUBL = {1}&amp;gt;} Aggr(&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;Count({$&amp;lt;PCHA_VALUE_GB -= {'-'}, PCHA_PUBL = {1}&amp;gt;} PBGA_BG_NO)/&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;Max({&amp;lt;PCHA_PUBL = {1}&amp;gt;}Aggr(NODISTINCT Count({&amp;lt;PCHA_PUBL = {1}&amp;gt;}PBGA_BG_NO), PAGA_GA_ID))&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;, PCHA_CHAR_ID, PAGA_GA_ID, PCHA_CHAR_GB))&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;, PAGA_GA_ID), '##0,0 %')&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;The oly distinguishing fact between the two columns "&lt;EM&gt; coverage all...&lt;/EM&gt;" and "&lt;EM&gt;coverage proposed..&lt;/EM&gt;." is that &lt;EM&gt;proposed&lt;/EM&gt; needs an additional condition where I delimit the characteristics (PCHA_CHAR_ID) that exceed a certain count since they also exist in another field:&lt;BR /&gt;&lt;BR /&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;PCHA_CHAR_ID = {"=Count(DISTINCT PCHA_CHAR_ID=PCGA_CHAR_ID) &amp;gt; 1"}&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;These are the orange columns of the second row and this is what I need the average of.&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;FONT color="#000000"&gt;I think it all comes down to the question where to add this line into the statement more above to make it work s&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT color="#000000"&gt;&lt;FONT color="#000000"&gt;ince the&amp;nbsp;dimension&amp;nbsp;"coverage all characteristics" is working.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;FONT color="#000000"&gt;Even when I currently select a certain value, the result is wrong since I expect &lt;STRONG&gt;45.75%&lt;/STRONG&gt;&amp;nbsp;as "&lt;EM&gt;coverage proposed...&lt;/EM&gt;" but end up with &lt;STRONG&gt;47.3%&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="avg6.jpg" style="width: 996px;"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/4426i95E89CBEE8E12E94/image-size/large?v=v2&amp;amp;px=999" role="button" title="avg6.jpg" alt="avg6.jpg" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;&lt;FONT color="#000000"&gt;I hope this helps.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Jan 2019 16:01:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1534633#M439065</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2019-01-24T16:01:42Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1534687#M439068</link>
      <description>&lt;P&gt;What exactly is this saying?&lt;/P&gt;&lt;PRE&gt;PCHA_CHAR_ID = {"=Count(DISTINCT PCHA_CHAR_ID=PCGA_CHAR_ID) &amp;gt; 1"}&lt;/PRE&gt;&lt;P&gt;I don't think I understand the issue to be able to respond you with the correct expression.&lt;/P&gt;</description>
      <pubDate>Thu, 24 Jan 2019 17:11:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1534687#M439068</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-01-24T17:11:37Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1539053#M439324</link>
      <description>&lt;P&gt;Hi Sunny,&lt;BR /&gt;&lt;BR /&gt;just to inform you: The passage you mentioned caused more trouble than it helped so I overworked my data model to get rid of that calculation.&lt;BR /&gt;Thereby I was able to exchange&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#FF0000"&gt;PCHA_CHAR_ID = {"=Count(DISTINCT PCHA_CHAR_ID=PCGA_CHAR_ID) &amp;gt; 1"}&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;to the much more useable &lt;FONT color="#008000"&gt;PCGA_PROP = {1}&lt;/FONT&gt;&amp;nbsp;and it now works fine in that particular chart.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#008000"&gt;=num(Aggr(&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#008000"&gt;Avg({&amp;lt;PCHA_PUBL = {1}, PCGA_PROP={1}&amp;gt;} Aggr(&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#008000"&gt;(Count({$&amp;lt;PCHA_VALUE_GB-={'-'}&amp;gt;}distinct PBGA_BG_NO) + Count({$&amp;lt;PCHA_IRRELEVANT= {1}&amp;gt;}distinct PBGA_BG_NO))&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#008000"&gt;/ &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#008000"&gt;max(aggr(nodistinct Count(distinct PBGA_BG_NO), PAGA_GA_ID))&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#008000"&gt;, PCHA_CHAR_ID, PAGA_GA_ID, PCHA_CHAR_GB))&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#008000"&gt;, PAGA_GA_ID), '##0 %')&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 04 Feb 2019 12:00:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1539053#M439324</guid>
      <dc:creator>citizenk</dc:creator>
      <dc:date>2019-02-04T12:00:56Z</dc:date>
    </item>
    <item>
      <title>Re: result of avg() dimension differs from expectation</title>
      <link>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1539065#M439326</link>
      <description>&lt;P&gt;Sounds good. I am glad you managed to resolved this all by yourself &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 04 Feb 2019 12:18:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/result-of-avg-dimension-differs-from-expectation/m-p/1539065#M439326</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2019-02-04T12:18:27Z</dc:date>
    </item>
  </channel>
</rss>

