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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Anonymous
Not applicable

Help with the Dax to find the average.

Hello All,

 

I have a table similar to this:

t1.PNG

 

I need to find the average of "ID" with the maximum "value" of each "num".

 

In this case - I need the average of A to be = (5+6+7)/(3) = 6.

 

Looking forward to your help!

1 ACCEPTED SOLUTION
Anonymous
Not applicable

hi @Anonymous 

Create this measure

Measure = CALCULATE(AVERAGEX('Table',CALCULATE(MAX('Table'[Value]),ALLEXCEPT('Table','Table'[ID],'Table'[Num]))),ALLEXCEPT('Table','Table'[ID]))

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

hi @Anonymous 

Create this measure

Measure = CALCULATE(AVERAGEX('Table',CALCULATE(MAX('Table'[Value]),ALLEXCEPT('Table','Table'[ID],'Table'[Num]))),ALLEXCEPT('Table','Table'[ID]))
Anonymous
Not applicable

Thank for your quick response. But I just forgot to mention that "Value" is a calculated measure and it shows an error if I try to include it in Max.

What should I do now?

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.

Top Solution Authors