Forum Discussion
Not able to create a monthly moving average based on a calculated turnover percentage
Hi everyone, I hope this community can help me with a solution to my problem. My googling have not yet given any results unfortunately.
My problem is:
I have a report named 'HR Trended Turnover' which have one row per supervisory organization.
My dashboard have slicers where organizations can be seleced.
In order to calculate the turnover percentage, I have created a quick measure called 'Frivillig turnover i prosent':
Hi!
your solution worked out prefectly, even with my filters!
Thank you very much. Appreciate your help!
4 Replies
- V-lianl-msft
Community Support
Hi ,
You may have a look at below posts.
https://community.powerbi.com/t5/Desktop/Moving-Average-for-Prev-6-Next-6-Months/td-p/171712
https://community.powerbi.com/t5/Desktop/Averages-For-The-Last-12-Months/td-p/324289
https://www.sqlbi.com/articles/rolling-12-months-average-in-dax/
Sample data and expected output will be helpful to provide an accurate solution.
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.- AndreBVFrequent Visitor
Hi Liang, thank you for your suggestions. I have read and have still not been able to create a moving average for turnover.
Perhaps it is obvious to you which mistakes I am making if I share my files?
PBIX file:
https://drive.google.com/file/d/1_dv7UJzMxHmbef5AE3SGwfj_2WFUn6ov/view?usp=sharing
Data file:
https://drive.google.com/file/d/12p4z2cScRyYezVbwovJ9F3VXroBFq1TL/view?usp=sharing
Thank you,
BR
André
- V-lianl-msft
Community Support
Try:
Measure = CALCULATE( AVERAGEX(VALUES(Kalender[Month-Year]),[Total turnover precentage]), FILTER(ALL(Kalender), COUNTROWS( FILTER(Kalender, Kalender[month year]>=EARLIER(Kalender[month year]) ) ) ),DATESINPERIOD(Kalender[Date],TODAY(),-6,MONTH) )