Forum Discussion

Mourt's avatar
Mourt
Helper I
3 years ago
Solved

Incorrect Average Result

Hi 

I have a table that consists of 2 columns (Type,Value) there are some values that are blank means they are Zeros

I want to calculate the average of values including the blanks (ex Average of type A = (0.5+0.2+0)/3 not (0.5 +0.2)/2

I tried 

AVERAGEX(SUMMARIZE(VALUES('Table'[type]),'Table'[type],"_value",AVERAGEX('Table','Table'[value])),[_value])



typevalue
A0.5
A0.2
A 
B0.8
B0.1
C 
D0.3
E0.4
F0.2
F 
  • values ignores blanks, it would be best to set those blank values to 0 or use distinctcount which counts blanks

1 Reply

  • vanessafvg's avatar
    vanessafvg
    Community Champion

    values ignores blanks, it would be best to set those blank values to 0 or use distinctcount which counts blanks