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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Zyg_D
Continued Contributor
Continued Contributor

Comparing to average

This is my simplified data:

image.png

Actually I only have the first 3 columns (no last blue column). I tried to create it, but I failed. I think I need it, because my final goal is to create a pie chart with only 2 pieces (above/below average) of only area1. Smth like this:

image.png

How should I go about it?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Would it work with calculated column?

above/below = IF(AVERAGE('Table'[grade]) > 'Table'[grade], "below average", "above average")

 

View solution in original post

3 REPLIES 3
v-kelly-msft
Community Support
Community Support

Hi @Zyg_D ,

 

If you wanna create a pie chart,you need to create a calculated column as below:

 

above/below = 
var _ave=AVERAGEX(FILTER('Table','Table'[area ]="Area 1"),'Table'[grade]) Return
IF('Table'[grade]>_ave,"above average","below average")

 

Finally,you will see:

Annotation 2020-05-07 152729.png

For the related .pbix file,pls click here.

 

Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!
amitchandak
Super User
Super User

@Zyg_D ,

Try

Above or Below = IF(AVERAGEX(all('Table'),'Table'[grade]) > 'Table'[grade], "Below average", "Above average")
Above or Below = IF(calculate(AVERAGE('Table'[grade]),allexcept('Table','Table'[grade])) > 'Table'[grade], "Below average", "Above average")
Anonymous
Not applicable

Would it work with calculated column?

above/below = IF(AVERAGE('Table'[grade]) > 'Table'[grade], "below average", "above average")

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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