Forum Discussion
Problem with Pareto
Hi guys,
I'm having trouble creating a logic for the pareto chart, here's the example:
I need to create a measure so that in cases where the (% acc) is below 80% I can take the next value above 80% and make a filter with it.
Bellow the expected result:
As you can see, if I were to plot the pareto at 80%, my maximum value would be 76.20%, however, I need that in those cases where the value does not reach 80%, the measure created should take the next value above 80%.
- Anonymous5 years ago
Hi rminto73 ,
According to my understanding, if the set value ——80% cannot be found in the aac% column, then it will be displayed: all values less than 80% and the first value greater than 80%,right?
You could use:
Measure = VAR _flag = IF ( 0.8 IN ALL ( 'Table'[% acc] ), TRUE (), FALSE () ) VAR _first = MINX ( FILTER ( ALL ( 'Table' ), 'Table'[% acc] > 0.8 ), [% acc] ) RETURN IF ( _flag = TRUE () && MAX ( 'Table'[% acc] ) <= 0.8, 1, IF ( _flag = FALSE () && MAX ( 'Table'[% acc] ) <= _first, 1, 0 ) )After applying it to visual-level filter pane, the final output is shown below:
Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
2 Replies
- Jihwan_KimSuper User
Hi,
Please correct me if I understood wrongly.
If there are not matching values with 80%, then you want to show the result with one more value that is the lowest value of above 80%s, right?
If I may suggest, please try to create VAR inside the measure, which indicates the lowest rank among over 80%s. Then, you can calculate or describe the outcome until that rank.The VAR might look something like the below.
VAR minimumrankingaboveeighty% =
Calculate (MINX (virtual-ranking-percentage-table, rank), percentage-column >= 80%) - AnonymousNot applicable
Hi rminto73 ,
According to my understanding, if the set value ——80% cannot be found in the aac% column, then it will be displayed: all values less than 80% and the first value greater than 80%,right?
You could use:
Measure = VAR _flag = IF ( 0.8 IN ALL ( 'Table'[% acc] ), TRUE (), FALSE () ) VAR _first = MINX ( FILTER ( ALL ( 'Table' ), 'Table'[% acc] > 0.8 ), [% acc] ) RETURN IF ( _flag = TRUE () && MAX ( 'Table'[% acc] ) <= 0.8, 1, IF ( _flag = FALSE () && MAX ( 'Table'[% acc] ) <= _first, 1, 0 ) )After applying it to visual-level filter pane, the final output is shown below:
Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.