Forum Discussion
Average calculation
- Anonymous4 years ago
Hi pva
How did you get 4.5 when you use (2+5+3+4)/4 ? The correct answer is 3.5 .
For 5125 , the final result is 3.5 -> ((4+6)/2+2+3+4)/4 .For 2147 , the final result is 4.667 -> ((2+4)/2+8+3)/3 . So the final average is 4.08 ->(3.5+4.667)/2
To realize the final average , you need to nest an AVERAGEX() outside the formula provided by SU .
Avg =AVERAGEX(VALUES('Table'[Code]),calculate(AVERAGEX(VALUES('Table'[Period]),CALCULATE(AVERAGE('Table'[Hours])))))The final result is as shown :
I have attached my pbix file , you can refer to it .
Best Regard
Community Support Team _ Ailsa Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi pva
How did you get 4.5 when you use (2+5+3+4)/4 ? The correct answer is 3.5 .
For 5125 , the final result is 3.5 -> ((4+6)/2+2+3+4)/4 .For 2147 , the final result is 4.667 -> ((2+4)/2+8+3)/3 . So the final average is 4.08 ->(3.5+4.667)/2
To realize the final average , you need to nest an AVERAGEX() outside the formula provided by SU .
Avg =AVERAGEX(VALUES('Table'[Code]),calculate(AVERAGEX(VALUES('Table'[Period]),CALCULATE(AVERAGE('Table'[Hours])))))
The final result is as shown :
I have attached my pbix file , you can refer to it .
Best Regard
Community Support Team _ Ailsa Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.