Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

filter column

Dear community,  I calculate average per row via below formula,  MeasureAvgY = CALCULATE(AVERAGE('wash'[Y]), ALLEXCEPT('Table', 'Table'[C], 'Table'[S], 'Table'[L])) now it shows average value per...
  • v-alq-msft's avatar
    5 years ago

    Hello, @Helia9235

    According to your description, I created data to reproduce your scenario. The pbix file is attached at the end.

    Mesa:

    b1.png

    You can create a measure as follows.

    Result = 
    IF(
        ISINSCOPE('Table'[Category]),
        SUM('Table'[Y]),
        CALCULATE(
            AVERAGE('Table'[Y]),
            ALLEXCEPT('Table','Table'[Cluster],'Table'[Stain],'Table'[Determination Label])
        )
    )

    Result:

    b2.pngb3.png

    Best regards

    Allan

    If this post helps, then consider Accept it as the solution to help other members find it faster.