<?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 error un calc avg in graph in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573958#M213778</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hello &lt;/P&gt;&lt;P&gt;i have a table with 3 fields Month, date1 and date2. I need to show a bar chart&amp;nbsp; agregated by month that show the avg of days between two date fields.&lt;/P&gt;&lt;P&gt;In dimension i define the field month, in expresion i put the next expresion:&lt;/P&gt;&lt;P&gt;num(avg(H_MFECHA-H_MFECHA2),'####,##',',','.') &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the result of the avg in the bar chart are wrong.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;somebody know what is wrong?? &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 12 Feb 2014 08:59:37 GMT</pubDate>
    <dc:creator>dcd123456</dc:creator>
    <dc:date>2014-02-12T08:59:37Z</dc:date>
    <item>
      <title>error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573958#M213778</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hello &lt;/P&gt;&lt;P&gt;i have a table with 3 fields Month, date1 and date2. I need to show a bar chart&amp;nbsp; agregated by month that show the avg of days between two date fields.&lt;/P&gt;&lt;P&gt;In dimension i define the field month, in expresion i put the next expresion:&lt;/P&gt;&lt;P&gt;num(avg(H_MFECHA-H_MFECHA2),'####,##',',','.') &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the result of the avg in the bar chart are wrong.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;somebody know what is wrong?? &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 08:59:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573958#M213778</guid>
      <dc:creator>dcd123456</dc:creator>
      <dc:date>2014-02-12T08:59:37Z</dc:date>
    </item>
    <item>
      <title>Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573959#M213779</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Difficult to say without a data sample. One problem could be that the two dates aren't correctly interpreted as dates. Another possibility is that you have NULL values in the date fields.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To debug, I would start by removing the Num() function, and see what I get when I use&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Avg(H_MFECHA-H_MFECHA2)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Avg(H_MFECHA)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Avg(H_MFECHA2)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Avg(RangeSum(H_MFECHA,-H_MFECHA2))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HIC&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 09:05:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573959#M213779</guid>
      <dc:creator>hic</dc:creator>
      <dc:date>2014-02-12T09:05:16Z</dc:date>
    </item>
    <item>
      <title>Re: Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573960#M213780</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello&lt;/P&gt;&lt;P&gt;i have two files, one an excel with a example data set , in excel i have calculated the avg for the month abrl = 70,0714 but in the bar chart qv show 61,26, and for the month may = 81,03125 but QV show 66,29.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i have attached a pptx file with two screenshot of the qv barchart&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks in advance for your help&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;diego&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 10:05:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573960#M213780</guid>
      <dc:creator>dcd123456</dc:creator>
      <dc:date>2014-02-12T10:05:36Z</dc:date>
    </item>
    <item>
      <title>Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573961#M213781</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear DcD,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In above situation you can use Month as Dimension and&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try below expression&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=Avg(Interval(Date2-Date1,'D hh:mm'))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;BR /&gt;Kiran&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 10:20:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573961#M213781</guid>
      <dc:creator>kiranmanoharrode</dc:creator>
      <dc:date>2014-02-12T10:20:39Z</dc:date>
    </item>
    <item>
      <title>Re: Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573962#M213782</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When I load your Excel file into QlikView, I get &lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;the same numbers&lt;/EM&gt;&lt;/SPAN&gt; as you have in the Excel file: &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; April = 70.07&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; May = 81.03&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, it is something you do in your QlikView load script...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Bar chart.png" class="jive-image" src="/legacyfs/online/53014_Bar chart.png" /&gt;&lt;/P&gt;&lt;P&gt;HIC&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 10:38:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573962#M213782</guid>
      <dc:creator>hic</dc:creator>
      <dc:date>2014-02-12T10:38:11Z</dc:date>
    </item>
    <item>
      <title>Re: Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573963#M213783</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hello&lt;/P&gt;&lt;P&gt;the expresion &lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;=Avg(Interval(Date2-Date1,'D hh:mm'))&lt;/SPAN&gt; don't work, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks for your help&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;diego&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 10:44:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573963#M213783</guid>
      <dc:creator>dcd123456</dc:creator>
      <dc:date>2014-02-12T10:44:29Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573964#M213784</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hello&lt;/P&gt;&lt;P&gt;It's possible that the problem occurr when (H_MFECHA-H_MFECHA2)=0&lt;/P&gt;&lt;P&gt;i have attached another file with sample data, in excel the value of the avg is 51,63 but in QV bar chart is 77&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;is there any way to make the expresion to say that avg take also the records with value 0.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks in advance for your help&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;diego&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 12:32:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573964#M213784</guid>
      <dc:creator>dcd123456</dc:creator>
      <dc:date>2014-02-12T12:32:54Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573965#M213785</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No, its not. When I load this new Excel file into QlikView, &lt;SPAN style="text-decoration: underline;"&gt;I get 51,63 also in QlikView&lt;/SPAN&gt;. So, QlikView includes the zeros in the calculation. There must be something in your load script or in your bar chart that alters the data. Can you post your QlikView file?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HIC&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Bar chart2.png" class="jive-image" src="/legacyfs/online/53022_Bar chart2.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 12:42:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573965#M213785</guid>
      <dc:creator>hic</dc:creator>
      <dc:date>2014-02-12T12:42:21Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Re: Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573966#M213786</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hello Henric&lt;/P&gt;&lt;P&gt;i'm doing something wrong, i have created a new qv document with the excel thad i have attached abobe and my qv report grong result 77&lt;/P&gt;&lt;P&gt;i have attached que qv file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;diego&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 12:52:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573966#M213786</guid>
      <dc:creator>dcd123456</dc:creator>
      <dc:date>2014-02-12T12:52:53Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Re: Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573967#M213787</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Your Excel file uses the DD/MM/YYYY format on dates, but you have US date format in your script:&lt;/P&gt;&lt;P&gt;SET DateFormat='M/D/YYYY';&lt;/P&gt;&lt;P&gt;SET TimestampFormat='M/D/YYYY h:mm:ss[.fff] TT';&lt;/P&gt;&lt;P&gt;SET MonthNames='Jan;Feb;Mar;Apr;May;Jun;Jul;Aug;Sep;Oct;Nov;Dec';&lt;/P&gt;&lt;P&gt;SET DayNames='Mon;Tue;Wed;Thu;Fri;Sat;Sun';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This means that some dates are misinterpreted and the diffs between dates are calculated incorrectly. &lt;/P&gt;&lt;P&gt;Change your script to proper Spanish settings:&lt;/P&gt;&lt;P&gt;SET DateFormat='DD/MM/YYYY';&lt;/P&gt;&lt;P&gt;SET TimestampFormat='DD/MM/YYYY hh:mm:ss[.fff] TT';&lt;/P&gt;&lt;P&gt;SET MonthNames='ene;feb;mar;abr;may;jun;jul;ago;sep;oct;nov;dic';&lt;/P&gt;&lt;P&gt;SET DayNames='lun;mar;mié;jue;vie;sáb;dom';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you change the regional settings in Windows, QlikView will use these for new documents.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HIC&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 13:18:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573967#M213787</guid>
      <dc:creator>hic</dc:creator>
      <dc:date>2014-02-12T13:18:56Z</dc:date>
    </item>
    <item>
      <title>Re: Re: Re: Re: error un calc avg in graph</title>
      <link>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573968#M213788</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;it works ok&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;diego&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Feb 2014 13:21:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/error-un-calc-avg-in-graph/m-p/573968#M213788</guid>
      <dc:creator>dcd123456</dc:creator>
      <dc:date>2014-02-12T13:21:40Z</dc:date>
    </item>
  </channel>
</rss>

