Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi all!
First off, thank you in advance for your help. For something that seems so easy, this one defintely threw me for a whirlwind because of PBI's time intelligence.
I have data I need to calculate rolling averages for EXCLUDING weekends/Holidays. See below for Data Table:
Next I have a date table to signify a "Working Day" where "Working Day" = 2 See below for Date Table:
Next, I have the dashboard piece of it where I am trying to get a parameter for rolling days that calculates the average of the last x number of days EXCLUDING weekends/holidays (this is where I have gone crazy trying to calculate this). Here's what it looks like:
The Dax for Rolling Average:
Is there any way to exclude weekends/holidays for my rolling average calculation? What am I missing?
THANK YOU SO SO MUCH!!
Solved! Go to Solution.
Hi,
You may download my PBI file from here.
Hope this helps.
Hi,
I am not sure how much i can help but i would like to try. Can you share the download link of your PBI file.
Hi,
You may download my PBI file from here.
Hope this helps.
You are welcome.
hi again @Ashish_Mathur !!
one follow-up question for your great answer - how would I display just the period where the true rolling average begins? For example, If I had a 5 day rolling average, the first 5 days would NOT display in the visual and it would start at day 6 once there is a rolling average. Same if it was a 30 day rolling average in the parameter, it would start at day 31 of data on my visual.
THANK YOU!
Hi,
If you have a 5 day rolling average, then the SMA should start apearing from Day 5 itself (not from Day 6). You may download my PBI file from here.
Hope this helps.
@Ashish_Mathur wow, you are truly incredible - I aspire to code like you someday! Wish I could give it 10 thumbs up
You are welcome. Thank you for your kind words.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
100 | |
83 | |
76 | |
65 |
User | Count |
---|---|
120 | |
108 | |
98 | |
83 | |
77 |