Forum Discussion
Calculating average of measures
- 10 years ago
Asumming you don't have that summary table built out and you just want to plug the initial table into a matrix or table visual, here's a measure you can use (might be minor syntax errors, I'm not testing but I'm pretty sure the concept is sound):
AVERAGEX(SUMMARIZE(Table, Table[week], "Sum of Hours", SUM(Table[hours spent]), "Average available", AVERAGE(Table[Available hours for the week])), 1 - DIVIDE([Sum of Hours], [Average available]))
What do you have in PowerBI right now? Do you only have one table or have you built out that summary table at all yet? I think both of us assumed you had that summary table built out, which might be incorrect.
Asumming you don't have that summary table built out and you just want to plug the initial table into a matrix or table visual, here's a measure you can use (might be minor syntax errors, I'm not testing but I'm pretty sure the concept is sound):
AVERAGEX(SUMMARIZE(Table, Table[week], "Sum of Hours", SUM(Table[hours spent]), "Average available", AVERAGE(Table[Available hours for the week])), 1 - DIVIDE([Sum of Hours], [Average available]))
- aktripathi250610 years ago
Helper IV
Awesome. This is great.
Very good logic, solved the problem.
Thanks a lot truely.
- aktripathi250610 years ago
Helper IV
by using this formula I created the measure which calculates the average of 13 weeks i.e. 1 quarter, for different group.
Please find below the table which I got as an output.
Group Name Measure Sales 87.86% Marketing 98.98% manuf. 97.57% IT 99.86% DB 100.00% SSC 98.75% HR Comm 94.13% AB 96.48% DT 97.76% Ramp 99.25% Control 99.13% planning 95.08% Distr. 97.64% This is working fine, Now I am strugling to add one more addition in it..
How can we get the average of these numbers displaying in power bi table/matrix vidual?
Average 97.11% This is what I want to add.
Thanks.