Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
sjade
Regular Visitor

DAX for selecting team and average based on individuals

I have a table with a similar setup as follows: 

NameTeamSkill AreaRating
johnDESQL3
johnDEETL2
laurenDEETL3
sarahDBASQL2
sarah DBASSRS2
sarahDBAPowerBI2
benBISQL3
benBISSRS2
georgeBISQL3
georgeBISSRS3

 

I am trying to write a DAX measure to calculate which team has the highest average and also how to calculate that average -- thanks in advance!

1 ACCEPTED SOLUTION
tamerj1
Super User
Super User

Hi @sjade 

I assume that the result will be displayed in a card visual and the skill can be selected using a slicer. Then you may try

Best Performing Teams =
CONCATENATEX (
    TOPN (
        1,
        ADDCOLUMNS (
            SUMMARIZE ( Table, Table[Team] ),
            "@Average", CALCULATE ( AVERAGE ( Table[AreaRating] ) )
        ),
        [@Average], DESC
    ),
    Table[Team],
    UNICHAR ( 10 )
)
Best Score =
MAXX (
    TOPN (
        1,
        ADDCOLUMNS (
            SUMMARIZE ( Table, Table[Team] ),
            "@Average", CALCULATE ( AVERAGE ( Table[AreaRating] ) )
        ),
        [@Average], DESC
    ),
    Table[Team]
)

View solution in original post

1 REPLY 1
tamerj1
Super User
Super User

Hi @sjade 

I assume that the result will be displayed in a card visual and the skill can be selected using a slicer. Then you may try

Best Performing Teams =
CONCATENATEX (
    TOPN (
        1,
        ADDCOLUMNS (
            SUMMARIZE ( Table, Table[Team] ),
            "@Average", CALCULATE ( AVERAGE ( Table[AreaRating] ) )
        ),
        [@Average], DESC
    ),
    Table[Team],
    UNICHAR ( 10 )
)
Best Score =
MAXX (
    TOPN (
        1,
        ADDCOLUMNS (
            SUMMARIZE ( Table, Table[Team] ),
            "@Average", CALCULATE ( AVERAGE ( Table[AreaRating] ) )
        ),
        [@Average], DESC
    ),
    Table[Team]
)

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.