Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

Average is not working

Hi,   I have the numbers of customers of two months and want to show the average.   This visual is the sum of customers with code:  customer[count_no] = IF(ISBLANK(customer[name]),BLANK(),...
  • FreemanZ's avatar
    3 years ago

    hi Anonymous 

    try like:

    count_AVG =
    VAR _AverageTable =
        ADDCOLUMNS (
            VALUES ( 'Date'[Date].[Month] ),
            "count",

     CALCULATE(COUNT ( customer[count_no] ))

    RETURN
        AVERAGEX( _AverageTable, [count] )