Forum Discussion

lennox25's avatar
lennox25
Post Patron
1 year ago
Solved

Conditional Formatting- 2 Std Deviation below Average and 2 Std Deviation above Average

Hi,  Each Column is derived from a measure. Here is my measure Apples Percentage = VAR TotalSales = SUM('Table 2'[Total Sales]) VAR AppleSales =     CALCULATE(         SUM('Table 1'[Amount])...
  • Anonymous's avatar
    Anonymous
    1 year ago

    Hi lennox25 ,

    Thanks for marcelsmaglhaes's reply!
    And lennox25 , you can also use DAX to achieve this.
    Here is my sample data:

    I see that you seem to be involved in calculating 2 Std Deviation and Average, but I don't know exactly which values you are calculating for these two values, so I'll just substitute two random DAXs on my end, please replace them with the ones that you are actually using.

    AverageAmount = 
    CALCULATE(
        AVERAGE('Table 1'[Amount]),
        ALLEXCEPT('Table 1', 'Table 1'[Score No], 'Table 1'[Category])
    )
    STDEVAmount = 
    CALCULATE(
        STDEV.P('Table 1'[Amount]),
        ALLEXCEPT('Table 1', 'Table 1'[Score No], 'Table 1'[Category])
    )

    And the final output is as below:


    Best Regards,
    Dino Tao
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.