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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
knamburi
Frequent Visitor

Calculating percentage of difference from total dataset average to a particular row

Hello All,

 

Looking for suggestion to solve a problem

 

triptime (column C ) is a measure column 

 

now i want to find the total average - of trip time which is 322.84 in this case and want to calculate how each driver is doing against average.

I tried using CALCULATE(AVERAGE(measure))  and few other methods but did not work

 

below is the example to calculate Average %

 

knamburi_0-1708125705564.png

 

any help is appreciated. 

 

Regards,

K

 

1 ACCEPTED SOLUTION
Ahmedx
Super User
Super User

Based on your description, I created data to reproduce your scenario. The pbix file is attached in the end.

Screenshot_1.png

View solution in original post

4 REPLIES 4
knamburi
Frequent Visitor

Thank you so much - this really solved my problem. Missing REMOVEFILTERS() - i never thought about it

 

But i have another question, this will disable all the filters - how can i exclude few specific - like i want to use few - i tried using KEEPFILTERS() but i guess its not working as expected.

to exclude something specific you need to use ALLEXCEPT functions
or additionally write VALUES:

m1 = CALCULATE(
[total average],REMOVEFILTERS(),VALUES('table'[Category]),
VALUES('table'[Year]))
Ashish_Mathur
Super User
Super User

Hi,

Share the download link of the PBI file.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Ahmedx
Super User
Super User

Based on your description, I created data to reproduce your scenario. The pbix file is attached in the end.

Screenshot_1.png

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

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.