Forum Discussion

badger123's avatar
badger123
Icon for Resolver I rankResolver I
7 years ago
Solved

Rank with visual filters applied

I have created a rank measure which ranks items in based on size:     Rank = RANKX(ALLSELECTED('Table1') ,CALCULATE(SUM('Table1'[Size])))     I also have a measure to calculate the mode of cate...
  • v-yulgu-msft's avatar
    7 years ago

    Hi badger123 ,

     

    Does this measure meet your requirement?

    CatMode = MINX (
    TOPN (1,
    ADDCOLUMNS (ALLEXCEPT( 'Table1', Table1[Item]),
    "Frequency", CALCULATE ( COUNT ( 'Table1'[Category] ) )
    ),
    [Frequency],
    0
    ),
    'Table1'[Category]
    )

     

    If not, please provide more description about your desired output. What is the expected result returned by measure [CatMode] in a table visual? I tested with your provided formula and got below result. In that case, why not directly apply filters on column [Category]?

    Best regards,

    Yuliana Gu