<?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: Measure for average monthly total.  AVERAGEX not quite right for this scenario in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4009359#M157607</link>
    <description>&lt;P&gt;Hi Alexis.&amp;nbsp; Is there anything you can suggest?&amp;nbsp; Thisis one of what shoulb become about 15 such dashboards (for different programs)&amp;nbsp; and I would really appreciate understanding how to create this measure.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 25 Jun 2024 14:52:30 GMT</pubDate>
    <dc:creator>Ohappyday</dc:creator>
    <dc:date>2024-06-25T14:52:30Z</dc:date>
    <item>
      <title>Measure for average monthly total.  AVERAGEX not quite right for this scenario</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/3993692#M155069</link>
      <description>&lt;P&gt;Hi.&amp;nbsp; I would like to build a measure that provides the average monthly total of volunteers, so I don't have to provide a huge total i.&amp;nbsp; SUMX provides the total (see visualization), while AVERAGE X returns the monthly average &lt;EM&gt;per provider&lt;/EM&gt;.&amp;nbsp;&lt;/P&gt;&lt;P&gt;For example, if November is picked in the slicer, Volunteers active (duplicated by month) returns 359 (69+129+60+101), but AVERAGEX returns 89.75 (359/4 because there are four providers).&amp;nbsp; &amp;nbsp; &amp;nbsp;I've tried countrows and spent a good deal of time trying various different approaches, unsuccessfully.&amp;nbsp;&amp;nbsp;Thank you for any help you can provide.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;Here are the measures I'm currently using:&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Volunteer hours received by consumers = &lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;SUMX(&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;FILTER('Assessment Questions', &lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;[Question]= "# of volunteer hours received by consumers for reporting month not reported by another agency"), [Response])&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;All Provider Expenses = &lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;SUMX('Invoice Expense',&lt;/EM&gt;&lt;BR /&gt;&lt;EM&gt;'Invoice Expense'[Invoice Amount])&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Jun 2024 16:13:29 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/3993692#M155069</guid>
      <dc:creator>Ohappyday</dc:creator>
      <dc:date>2024-06-14T16:13:29Z</dc:date>
    </item>
    <item>
      <title>Re: Measure for average monthly total.  AVERAGEX not quite right for this scenario</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/3993874#M155070</link>
      <description>&lt;P&gt;The key is to aggregate at the level of granularity you need before you take an average.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Try writing your logic along these lines:&lt;/P&gt;
&lt;LI-CODE lang="php"&gt;VAR _MonthlyHours_ =
    SUMMARIZE ( Dates, Dates[Month], "@TotalHours", [Volunteeer hours] )
RETURN
    AVERAGEX ( _MonthlyHours_, [@TotalHours] )&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 14 Jun 2024 18:30:28 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/3993874#M155070</guid>
      <dc:creator>AlexisOlson</dc:creator>
      <dc:date>2024-06-14T18:30:28Z</dc:date>
    </item>
    <item>
      <title>Re: Measure for average monthly total.  AVERAGEX not quite right for this scenario</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4002557#M156064</link>
      <description>&lt;P&gt;Hi Alexis.&amp;nbsp; Thank you for your help!&amp;nbsp; I am learning DAX and may not be implementing your suggestion correctly.&amp;nbsp; I tried creating a new measure using the code below but received this error:&amp;nbsp;&amp;nbsp;&lt;EM&gt;The syntax for 'RETURN' is incorrect.&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;VAR&lt;/SPAN&gt;&lt;SPAN&gt; _MonthlyHours_ =&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;SUMMARIZE&lt;/SPAN&gt;&lt;SPAN&gt; ( &lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'&lt;/SPAN&gt;&lt;SPAN&gt;[Month]&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;"@TotalHours"&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;[Volunteer hours received by consumers]&lt;/SPAN&gt;&lt;SPAN&gt; )&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;RETURN&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;AVERAGEX&lt;/SPAN&gt;&lt;SPAN&gt; ( &lt;/SPAN&gt;&lt;SPAN&gt;_MonthlyHours_&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;[@TotalHours]&lt;/SPAN&gt;&lt;SPAN&gt; )&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;I tried creating a new table with the same code and received the same error.&lt;BR /&gt;&lt;BR /&gt;Do you have any further suggestions?&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 20 Jun 2024 17:15:35 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4002557#M156064</guid>
      <dc:creator>Ohappyday</dc:creator>
      <dc:date>2024-06-20T17:15:35Z</dc:date>
    </item>
    <item>
      <title>Re: Measure for average monthly total.  AVERAGEX not quite right for this scenario</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4002830#M156109</link>
      <description>&lt;P&gt;That's not an error I'd expect with that code. Can you share a screenshot of your Power BI Desktop so I can check to see if you've missed something like naming the measure? (I didn't provide a name, so you'll definitely get some sort of error if you paste my code block in without adding one.)&lt;/P&gt;</description>
      <pubDate>Thu, 20 Jun 2024 21:50:17 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4002830#M156109</guid>
      <dc:creator>AlexisOlson</dc:creator>
      <dc:date>2024-06-20T21:50:17Z</dc:date>
    </item>
    <item>
      <title>Re: Measure for average monthly total.  AVERAGEX not quite right for this scenario</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4004134#M156256</link>
      <description>&lt;P&gt;Hi.&amp;nbsp; Yes, there is so much about DAX that I don't know, I probably have made an obvious error, or more than one.&amp;nbsp; Is this what you are looking for?&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 21 Jun 2024 13:02:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4004134#M156256</guid>
      <dc:creator>Ohappyday</dc:creator>
      <dc:date>2024-06-21T13:02:38Z</dc:date>
    </item>
    <item>
      <title>Re: Measure for average monthly total.  AVERAGEX not quite right for this scenario</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4004161#M156260</link>
      <description>&lt;P&gt;This is my date calendar.&amp;nbsp; I wasn't sure if I should use &lt;EM&gt;Month&lt;/EM&gt; or &lt;EM&gt;Year Month&lt;/EM&gt; in the &lt;EM&gt;groupBy_columnName&amp;nbsp;&lt;/EM&gt;parameter.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 21 Jun 2024 13:15:37 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4004161#M156260</guid>
      <dc:creator>Ohappyday</dc:creator>
      <dc:date>2024-06-21T13:15:37Z</dc:date>
    </item>
    <item>
      <title>Re: Measure for average monthly total.  AVERAGEX not quite right for this scenario</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4009359#M157607</link>
      <description>&lt;P&gt;Hi Alexis.&amp;nbsp; Is there anything you can suggest?&amp;nbsp; Thisis one of what shoulb become about 15 such dashboards (for different programs)&amp;nbsp; and I would really appreciate understanding how to create this measure.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 25 Jun 2024 14:52:30 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-for-average-monthly-total-AVERAGEX-not-quite-right-for/m-p/4009359#M157607</guid>
      <dc:creator>Ohappyday</dc:creator>
      <dc:date>2024-06-25T14:52:30Z</dc:date>
    </item>
  </channel>
</rss>

