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.
Hello all, I am having trouble figuring out how to compare the same measure against itself while being altered by different filters.
For example, I am creating a dashboard to compare the emissions of a specific site location (on the left) against the average of many site locations (on the right). The averages on the right can be filtered by a slicer that can be filtering by Region, Business Unit, and Facility Type. So there are 3 filtering criteria that can be selected. The left is only examining one facility at a time, the Facility Names. In the example below, the site on the left has been selected and the right side is the average for all Manufacturing sites, but could theorectically be honed down to Manufacturing, Business Unit B, Region: America, etc.
I want to add a measure that calculates the percent difference between the site selected and the average on the right side. So if we were looking at Electricity Usage, I want a little logo that shows the site on the left is 17% greater than that of the average for all manufacturing sites. This is the same measure however, just the one on either side is being altered by different slicers. The measure is FilteredElectricity[ElecUsageAvg] and I want to be able to compare it to itself based on what the slicers currently have selected. I attached a table with some data just to help visualize what I'm working with, any help here would be greatly appreciated!
Facility Names | Region | Business Unit | Facility Type | Elec Usage |
Detroit | America | Unit A | Factory | 1,000,000 |
New York | America | Unit B | Factory | 2,000,000 |
Glasgow | Europe | Unit A | Office | 30,000 |
Frankfurt | Europe | Unit A | Office | 50,000 |
you cannot measure a measure. You will have to create a separate measure that implements the comparison logic from scratch.
How do I implement the comparison logic in side a new measure that accounts for the changing slicers?
Measures operate within the filter context - which automatically includes the slicer choices. So you get that part "for free".
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 |
---|---|
107 | |
99 | |
76 | |
64 | |
58 |
User | Count |
---|---|
148 | |
113 | |
97 | |
84 | |
67 |