Forum Discussion

jonasr's avatar
jonasr
Advocate I
8 years ago
Solved

DAX Measure calculating COUNT based on condition over calculated average value

Hi, I am struggling to find the right way to calculate the count of people that have average value of some variable above certain treshold and show this number in a Card visual.   Basically, I have...
  • jonasr's avatar
    8 years ago

    Solved it. This worked:

    ScoreBelow0.8 = 
    COUNTROWS(
        FILTER(
            SUMMARIZE (
            'table',
            'table'[employee_id],
            "SCORE", 
                AVERAGE('report sector_member'[Score])
             ),
        [SCORE] < 0.8 && ISBLANK([SCORE]) = FALSE
        ) 
    )

     

    The major issue was handling of BLANK values in Score column in subsequent filtering.