Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
PhoenixBird66
Helper III
Helper III

DAX measure with multiple FILTERs

I want to create a measure called "Excluding Outliers" - it needs to return the value of [January % Increase], but if that value is greater than 100% or less than -100% it should return a blank. Also, if the StdSvcKey field is blank, it should return a blank value.

Any ideas of the best way of doig this? Any help would be greatly appreciated as I'm a bit stuck.

ExcludeOutliers.JPG

 

1 ACCEPTED SOLUTION
Mariusz
Community Champion
Community Champion

Hi @PhoenixBird66 

This is how corrected measure shoud look like
 
Excluding Outliers =
VAR x = [January % Increase]
RETURN
CALCULATE(
[January % Increase],
FILTER(
Sales,
x >= -1 && x <= 1
),
ISBLANK(Sales[StdSvcKey]) = FALSE
)

Thanks 
Mariusz

View solution in original post

5 REPLIES 5
Mariusz
Community Champion
Community Champion

Hi @PhoenixBird66 

Excluding Outliers =
VAR x=  [January % Increase]
RETURN
CALCULATE(
[January % Increase]
FILTER(
yourTable,
[January % Increase] >= -1 && [January % Increase] <= 1
),
ISBLANK(yourTable[StdSvcKey]) = FALSE
)

Thanks for replying. Doesnt seem to like the FILTER...

 

Capture.JPG

 

Hi @PhoenixBird66,

 

Sorry, I missed the "," before the filter 

Mariusz

Mariusz
Community Champion
Community Champion

Hi @PhoenixBird66 

This is how corrected measure shoud look like
 
Excluding Outliers =
VAR x = [January % Increase]
RETURN
CALCULATE(
[January % Increase],
FILTER(
Sales,
x >= -1 && x <= 1
),
ISBLANK(Sales[StdSvcKey]) = FALSE
)

Thanks 
Mariusz

Yes this works - thanks so much for your help! I'm so happy! 🙂

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.