Forum Discussion
lukeSDM
Helper V
5 years agoWeekly Rolling average for already calculated measure
Hello, I am trying to create a weekly rolling average for my measure calculated attendance : "([AlL Present]/[Measure])*100" which is : "ALL Present = CALCULATE(COUNT(AttendanceOvertime[St...
- 5 years ago
Below are the formulas for all the measures I'm using. Without seeing what you're expected result based on the data provided, it's kind of difficult to figure out what, if anything, is wrong. Could you please provide some details?
ALL Present:=CALCULATE( COUNTROWS(AttendanceOvertime), AttendanceOvertime[Statistical meaning] IN {"Present", "Approved Educational Activity"} ) ALL Present Running Total:=CALCULATE( [ALL Present], FILTER( ALL('Calendar'), 'Calendar'[Date] <= MAX('Calendar'[Date]) ) ) Measure:=CALCULATE ( COUNT ( AttendanceOvertime[Statistical meaning] ), AttendanceOvertime[Statistical meaning] IN { "Attendance not required" } ) Measure Running Total:=CALCULATE( [Measure], FILTER( ALL('Calendar'), 'Calendar'[Date] <= MAX('Calendar'[Date]) ) ) All Present Running Average:=DIVIDE( [ALL Present Running Total], [Measure Running Total], BLANK() )
littlemojopuppy
Community Champion
5 years agoThe DAX formula I provided won't work for that. Sounds like more of a running average of weeks...assuming weeks run Sunday to Saturday?
Can you provide some sample data to play with?
- lukeSDM5 years ago
Helper V
This is what my data looks like, does this help.
- littlemojopuppy5 years ago
Community Champion
Would be easier if you could provide an actual (anonymous) data to work with instead of a screen shot
- lukeSDM5 years ago
Helper V