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.
This should be simple but I can't get a threshold parameter to work using what if. I saw a worked example and did exactly that but it fell over at the last step.
I have a table of sales opportunities and each has a probability of success value. I want to have a slicer that filters out all rows less than the value in the slicer so users can dynamically set the threshold for which opportunities are displayed.
I created a measure "Include = if([Probability]<0.5,0,1)" and for each row in the table it correctly shows whether the value is less than 50% or not. Setting the visualisation filter to "Include is 1" correctly displays the table with only those rows with a Probability of 50% or higher.
I created a "what if" parameter and associated table and can get the slicer to show the selected value. I included the "Probability Select Value" in the table and as you move the slider up and down on the slicer the value on each row updates accordingly - so far so good. The example says that the last step is to replace the literal "0.5" in the formula with the what if parameter value. In the example it works perfectly, but in my case the "Include" measure is always "1".
I tried to create a measure equal to the Probability column in case the formula didn;t like the mix of columns and measures, but Power BI won't let me do that - I can only create a measure with the other measures. I can't even re-crerate the original include measure now. I can edit it back to using the literal, but I can't type it in from scratch any more, or even copy it to a new measure and change the name - WTF (Welcome To Frustration)
Solved! Go to Solution.
@trevor,
Is Probability a existing column in your table? If so, please create the what if parameter as shown in the following screenshot, then create a measure rather than a column in your original table.
Measure 2 = IF(MAX(Table[probability])<Parameter[Parameter Value],0,1)
Regards,
Lydia
@trevor,
Is Probability a existing column in your table? If so, please create the what if parameter as shown in the following screenshot, then create a measure rather than a column in your original table.
Measure 2 = IF(MAX(Table[probability])<Parameter[Parameter Value],0,1)
Regards,
Lydia
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 |
---|---|
111 | |
95 | |
80 | |
68 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |