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
Kamaizziati
Helper IV
Helper IV

To show top 20% total value

 

Hi All,

 

I need to show top 20% of total value data. 

How to do it and show in table and bar graft

 

Problem Below:

 

I have data (figure below) , I want to show the top 20% of data description.

Then, the table data should be show only Self Learning, Vacation and General.

 

2018-08-10_0953.png

 

Or can apply it on bar graph ( Have a mark to show that is the top 20% total value).

 

 

 

 

1 ACCEPTED SOLUTION
v-yulgu-msft
Employee
Employee

Hi @Kamaizziati,

 

Suppose [%GT Hours] is a measure, then, based on it, please create a below measures:

rank = RANKX(ALLSELECTED('Table'),[%GT Hours],,DESC,Dense)
Check is Top 20% = IF([rank]<=CALCULATE(COUNTROWS('Table'),ALLSELECTED('Table'))*0.2,1,0)

And [Check is Top 20%] into visual level filters, and set it value to equal 1.

 

Regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-yulgu-msft
Employee
Employee

Hi @Kamaizziati,

 

Suppose [%GT Hours] is a measure, then, based on it, please create a below measures:

rank = RANKX(ALLSELECTED('Table'),[%GT Hours],,DESC,Dense)
Check is Top 20% = IF([rank]<=CALCULATE(COUNTROWS('Table'),ALLSELECTED('Table'))*0.2,1,0)

And [Check is Top 20%] into visual level filters, and set it value to equal 1.

 

Regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @v-yulgu-msft,

 

Im create the %GT Hours from power bi calculation (figure below) that is Percent of grand total.

 

How I want create DAX measure for %GT Hours.

 

Thank You2018-08-28_1215.png

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.