Forum Discussion

sscott's avatar
sscott
New Member
2 years ago
Solved

Grouping columns based on column in table

Hi

 

I have the following matrix visual. I'm trying to produce another visual that shows the subjects but with the grades grouped. The issue is that the subjects can change over ttime.

 

So for example I want to group the grades as follows -

 

0-9

1-9

2-9

3-9

4-9

5-9

6-9

7-9

8-9

 

Here is the current matrix visual for reference

 

 

 

  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi sscott ,

     

    I create simple data as follows:

     

     

    The relationship between them:

     

    Please follow these steps:

     

    1.Create a measure:

     

     

     

    Measure =
    var sum1=CALCULATE(SUM('Table'[Percentage]),FILTER(ALL(Range),'Range'[Grade] >= MAX('Range'[Grade]) && 'Range'[Grade] <= 9))
    RETURN
    sum1

     

     

     

    2.Use range as columns and measure as values:

     

    The pbix file is attached.

     

    Best Regards,
    Zhu
    Community Support Team

     

    If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
    If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

1 Reply

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi sscott ,

     

    I create simple data as follows:

     

     

    The relationship between them:

     

    Please follow these steps:

     

    1.Create a measure:

     

     

     

    Measure =
    var sum1=CALCULATE(SUM('Table'[Percentage]),FILTER(ALL(Range),'Range'[Grade] >= MAX('Range'[Grade]) && 'Range'[Grade] <= 9))
    RETURN
    sum1

     

     

     

    2.Use range as columns and measure as values:

     

    The pbix file is attached.

     

    Best Regards,
    Zhu
    Community Support Team

     

    If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
    If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!