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

Data Days is here! Join us now for 60+ days of learning, challenges, and connection. Learn more

Reply
NaukkaUKKO
Frequent Visitor

Measures to display % of projects by date and percentage chance to win

Hello! I have been struggling with this task for a while now and i decided to ask for help. I have table with estimated cost, project name, date and percentage that project will be won.

I would like to create 3 different measures in one line chart

One which shows estimated cost of 50% of all projects by date and highest percentage change

Another line chart which shows estimated cost for 75% of the projects  by date and highest percentage change and third line chart which shows estimated cost for all projects by date

NaukkaUKKO_0-1634988098704.png


All columns are in one table. For example if we used example picture, the 50% estimate would show estimated cost of project a and project b, because they are 50% of all projects with higest percentage. 

I hope i made sense with my reguest!

1 ACCEPTED SOLUTION
v-yalanwu-msft
Community Support
Community Support

Hi, @NaukkaUKKO ;

You could create two measure as follows:

1.top 50%

Top50% = 
IF( RANKX(ALL('Table'),CALCULATE( MAX([percentage change])),,DESC)<=CALCULATE(DISTINCTCOUNT([Project name]),ALL('Table'))/2,1,0)

then apply it into line chart filter.

vyalanwumsft_0-1635212406774.png

2.top 75%

Top75% = 
IF( RANKX(ALL('Table'),CALCULATE( MAX([percentage change])),,DESC)<=3*CALCULATE(DISTINCTCOUNT([Project name]),ALL('Table'))/4,1,0)

then apply it into line chart filter.

vyalanwumsft_1-1635212440165.png

The final output is shown below:

vyalanwumsft_2-1635212472338.pngvyalanwumsft_3-1635212497295.png

vyalanwumsft_4-1635212515841.png

Best Regards,
Community Support Team_ Yalan Wu
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-yalanwu-msft
Community Support
Community Support

Hi, @NaukkaUKKO ;

You could create two measure as follows:

1.top 50%

Top50% = 
IF( RANKX(ALL('Table'),CALCULATE( MAX([percentage change])),,DESC)<=CALCULATE(DISTINCTCOUNT([Project name]),ALL('Table'))/2,1,0)

then apply it into line chart filter.

vyalanwumsft_0-1635212406774.png

2.top 75%

Top75% = 
IF( RANKX(ALL('Table'),CALCULATE( MAX([percentage change])),,DESC)<=3*CALCULATE(DISTINCTCOUNT([Project name]),ALL('Table'))/4,1,0)

then apply it into line chart filter.

vyalanwumsft_1-1635212440165.png

The final output is shown below:

vyalanwumsft_2-1635212472338.pngvyalanwumsft_3-1635212497295.png

vyalanwumsft_4-1635212515841.png

Best Regards,
Community Support Team_ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

hejszyszky
Helper II
Helper II

Hi, try something like below:

SumOfTop50%Projects = 
VAR vNumOfRows = countrows(table)
VAR vProjectsCost = calculate(sum(Estimated Cost))

Return
CALCULATE(
vProjectsCost,
TOPN(
vNumOfRows/2,
ALL(EstimatedCost),
vProjectsCost,
DESC)
)



Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 2026 Power BI update to learn about new features.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.