Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hi,
This is difficult to explain, but I will be as descriptive as possible and thanks in advance to anyone who can help with this.
I am working on creating a bar chart visual to show proportions and I am having trouble creating a measure that can allow for the numerator to be influenced by all filters, while only letting some filters influence the denominator.
My data comes from a survey question that asks respondents why they visited a website and presents them with 6 options to pick with their answer is stored as a code (1-6 for the six options). These 6 options have labels applied via a related table and are what make up the y-axis of my chart. Ideally I should have the % that each of the 6 options makes up from the full base size of those who answered (totalling 100%), but the labels on the chart are serving as filters for the denominator when I do not want them to, throwing off the % calculation.
Can anyone help me write a Measure where the numerator is filterable as normal, but the denominator does not filter based on the 6 options that make up the axis of the chart?
I am hoping this is something simple, but I am stumped on how to do this without hard coding the denominator and I do not want to do that as there are other filters that I would like to influence the chart and hard coding will prevent that.
Thanks,
Chris
Here is a visual of my chart to give you an idea of what I am talking about:
Does something like this work out?
Result Count := COUNTROWS(Results)
Result Count - ALL := CALCULATE([Result Count], ALL(Results))
Result % := DIVIDE([Result Count], [Result Count - ALL])
User | Count |
---|---|
128 | |
108 | |
99 | |
65 | |
62 |
User | Count |
---|---|
137 | |
115 | |
102 | |
71 | |
61 |