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.
Hi!
I want to calculate the difference between two rows based on filters applied from a plot.
The data is as an example below. When I mark "Apple" and "Banana" in the plot, I would like to have Power BI calculate the delta of weight of those two. (For this example: 100) Similar to any other two selected projects in the scatter plot.
I very much appreciate any effort of help!
Solved! Go to Solution.
Hi @jsils ,
You can create a new measure “delta”.
delta = ABS ( CALCULATE ( SUM ( 'Table'[Weight] ), FILTER ( 'Table', 'Table'[Name] = MAX ( 'Table'[Name] ) ) ) - CALCULATE ( SUM ( 'Table'[Weight] ), FILTER ( 'Table', 'Table'[Name] <> MAX ( 'Table'[Name] ) ) ) )
Then you can select a visual to display it. For example, I used the card visual.
Now, you can mark any two names and the delta will give a difference between them.
Best Regards,
Eads
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @jsils ,
You can create a new measure “delta”.
delta = ABS ( CALCULATE ( SUM ( 'Table'[Weight] ), FILTER ( 'Table', 'Table'[Name] = MAX ( 'Table'[Name] ) ) ) - CALCULATE ( SUM ( 'Table'[Weight] ), FILTER ( 'Table', 'Table'[Name] <> MAX ( 'Table'[Name] ) ) ) )
Then you can select a visual to display it. For example, I used the card visual.
Now, you can mark any two names and the delta will give a difference between them.
Best Regards,
Eads
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
94 | |
81 | |
66 | |
58 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |