Forum Discussion
sixtoquiles
9 years agoHelper II
Average from Measure
HI, I need help... I have 12 DAX to calculated a percent , my measure dax look like: percent1 = iferror(sum(pass1)/sum(pass1)+sum(fail1)),"-") percent2 = i...
- Anonymous9 years ago
Easiest way i can think of is this:
Average Rate1 = DIVIDE( [Percent Rate1] + [Percent Rate2] + [Percent Rate3], if( [Percent Rate1] > 0, 1, 0 ) + if( [Percent Rate2] > 0, 1, 0 ) + if( [Percent Rate3] > 0, 1, 0 ) )
- 9 years ago
Hi there, I could suggest a modification to Anonymous measure.
Average Rate1 = Var PercentRate1 = IF([Percent Rate1]>0,1,0) Var PercentRate2 = IF([Percent Rate2]>0,1,0) Var PercentRate3 = IF([Percent Rate3]>0,1,0)
Var PercentRates = PercentRate1 + PercentRate2 + PercentRate3 DIVIDE( [Percent Rate1] + [Percent Rate2] + [Percent Rate3], PercentRates )This just uses variables and puts them into a logical order, and then makes it easier to change it or update it going forward.
GilbertQ
8 years agoSuper User
hi Anonymous
Below is the updated measure
Average from Measure =
DIVIDE([Avg_Time],DISTINCTCOUNT('TableName'[Month]))Anonymous
8 years agoNot applicable
Hi GilbertQ
For some reason, its not working properly. Its showing a value = 43.77 instead of 141.72.
is there a way to sum of the average?