<?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: Rolling average with adjustable time frame in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4021627#M158686</link>
    <description>&lt;P&gt;I need the weekends to not count in the equation if possible, that was where I was having the most trouble. For example, if X equals 10 6/28/2024 should average the previous 10 existing figures to 6/14/2024. Weekend figures shouldn't be present&lt;/P&gt;</description>
    <pubDate>Wed, 03 Jul 2024 02:44:08 GMT</pubDate>
    <dc:creator>BryantSturn</dc:creator>
    <dc:date>2024-07-03T02:44:08Z</dc:date>
    <item>
      <title>Rolling average with adjustable time frame</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4019149#M158541</link>
      <description>&lt;P&gt;I'm having issues creating a measure to calculate the average over the past X days for a specific account. In the initial Data I have multiple rows per day for several accounts with a specific value recorded for each account, each day. The data is over a year and I need to come up with an average amount looking back X days, then compare the current days value to the average amount over the adjustable period. to calculate the average amount I have a query that almost works, it just looks at every day and creates an average instead of averaging over the days in the spreadsheet (which excludes weekends and holidays). How would I be able to fix this issue? I need to create a matrix which will show every value and then count the amount of times the specific day breaks the specified average value.&lt;/P&gt;&lt;P&gt;AverageAmountOverXDays =&lt;/P&gt;&lt;P&gt;VAR SelectedDays = SELECTEDVALUE(DaysP arameter[Days Parameter])&lt;/P&gt;&lt;P&gt;RETURN&lt;/P&gt;&lt;P&gt;CALCULATE(&lt;/P&gt;&lt;P&gt;AVERAGE('Table'[Amount]),&lt;/P&gt;&lt;P&gt;DATESINPERIOD('Date'[Date], MAX('Date' [Date]), -SelectedDays, DAY)&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;I also have a reference calendar that contains only dates from the data and a count to rank them. I couldn't figure out how to take advantage of it though.&lt;/P&gt;</description>
      <pubDate>Mon, 01 Jul 2024 20:44:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4019149#M158541</guid>
      <dc:creator>BryantSturn</dc:creator>
      <dc:date>2024-07-01T20:44:20Z</dc:date>
    </item>
    <item>
      <title>Re: Rolling average with adjustable time frame</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4019402#M158560</link>
      <description>&lt;P class="lia-align-left"&gt;Sounds like Numeric Parameters can handle this for you. How far back should X be?&lt;/P&gt;
&lt;P class="lia-align-left"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="lia-align-left"&gt;Please provide sample data that covers your issue or question &lt;STRONG&gt;completely&lt;/STRONG&gt;, in a &lt;STRONG&gt;usable&lt;/STRONG&gt; format (not as a screenshot).&lt;BR /&gt;&lt;BR /&gt;Do not include sensitive information or anything not related to the issue or question. &lt;BR /&gt;&lt;BR /&gt;If you are unsure how to upload data please refer to &lt;A href="https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216" target="_blank"&gt;https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216&lt;/A&gt; &lt;BR /&gt;&lt;BR /&gt;Please show the expected outcome based on the sample data you provided. &lt;BR /&gt;&lt;BR /&gt;Want faster answers? &lt;A href="https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523" target="_blank"&gt;https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523&lt;/A&gt;&lt;/P&gt;
&lt;P class="lia-align-left"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class="lia-align-left"&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 02 Jul 2024 01:39:21 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4019402#M158560</guid>
      <dc:creator>lbendlin</dc:creator>
      <dc:date>2024-07-02T01:39:21Z</dc:date>
    </item>
    <item>
      <title>Re: Rolling average with adjustable time frame</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4021422#M158671</link>
      <description>&lt;P&gt;For the attached file I would need a rolling average that only includes dates found in the data and is set by the parameter&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://usfedu-my.sharepoint.com/:u:/g/personal/bryantsturn_usf_edu/EfL24alnfCZGtNYj14gCZMMBcW-TNOIgbtYXjW_JatT_PA?e=l8iFd8" target="_blank" rel="noopener"&gt;RollingAverage.pbix&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If you need anything else please let me know!&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jul 2024 00:58:52 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4021422#M158671</guid>
      <dc:creator>BryantSturn</dc:creator>
      <dc:date>2024-07-03T00:58:52Z</dc:date>
    </item>
    <item>
      <title>Re: Rolling average with adjustable time frame</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4021437#M158672</link>
      <description>&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;See attached&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jul 2024 01:18:36 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4021437#M158672</guid>
      <dc:creator>lbendlin</dc:creator>
      <dc:date>2024-07-03T01:18:36Z</dc:date>
    </item>
    <item>
      <title>Re: Rolling average with adjustable time frame</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4021627#M158686</link>
      <description>&lt;P&gt;I need the weekends to not count in the equation if possible, that was where I was having the most trouble. For example, if X equals 10 6/28/2024 should average the previous 10 existing figures to 6/14/2024. Weekend figures shouldn't be present&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jul 2024 02:44:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4021627#M158686</guid>
      <dc:creator>BryantSturn</dc:creator>
      <dc:date>2024-07-03T02:44:08Z</dc:date>
    </item>
    <item>
      <title>Re: Rolling average with adjustable time frame</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4022792#M158728</link>
      <description>&lt;P&gt;What is your definition of weekend? What if there is a weekend day with data ? What if there is a weekday without data?&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jul 2024 11:39:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4022792#M158728</guid>
      <dc:creator>lbendlin</dc:creator>
      <dc:date>2024-07-03T11:39:58Z</dc:date>
    </item>
    <item>
      <title>Re: Rolling average with adjustable time frame</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4022871#M158737</link>
      <description>&lt;P&gt;Sorry for the confusion but the data does not include weekends (Saturday or Sunday) or holidays. I would like to not count those, preferably by only counting which days are provided.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jul 2024 12:24:14 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4022871#M158737</guid>
      <dc:creator>BryantSturn</dc:creator>
      <dc:date>2024-07-03T12:24:14Z</dc:date>
    </item>
    <item>
      <title>Re: Rolling average with adjustable time frame</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4022892#M158738</link>
      <description>&lt;P&gt;Do you need the column or row totals? They would be much more complex to get accurate with your new rules.&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;see attached.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jul 2024 12:50:45 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4022892#M158738</guid>
      <dc:creator>lbendlin</dc:creator>
      <dc:date>2024-07-03T12:50:45Z</dc:date>
    </item>
    <item>
      <title>Re: Rolling average with adjustable time frame</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4023013#M158745</link>
      <description>&lt;P&gt;Thanks that's perfect. I do not need row or column totals. The only total I need is to compare the calculated average and the current day value, then count the amount of times the current day exceeds the calculated average (for each account, not summed across for the day). These are example numbers but we're creating a threshold for a lookback period to present. We need to compare the amount of threshold breaks with the size of the lookback period.&lt;/P&gt;</description>
      <pubDate>Wed, 03 Jul 2024 13:45:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Rolling-average-with-adjustable-time-frame/m-p/4023013#M158745</guid>
      <dc:creator>BryantSturn</dc:creator>
      <dc:date>2024-07-03T13:45:58Z</dc:date>
    </item>
  </channel>
</rss>

