Forum Discussion
Filter by thresholds
- Anonymous4 years ago
Hi Anonymous ,
I created a sample pbix file(see attachment) for you, please check whether that is what you want.
1. Create a measure as below to make conditional formatting
Conditional formatting = VAR _tab = SUMMARIZE ( 'Table', 'Table'[date].[Month], "@qty", SUM ( 'Table'[qty] ) ) VAR _qty = SUMX ( _tab, [@qty] ) VAR _count = COUNTROWS ( FILTER ( _tab, [@qty] > 3 ) ) RETURN IF ( _count > 0, IF ( ( ISINSCOPE ( 'Table'[order] ) || ISINSCOPE ( 'Table'[item] ) || ISINSCOPE ( 'Table'[date] ) ), IF ( _qty > 3, "red" ), IF ( _qty > 5, "red" ) ) )2. Configure conditional formatting
If the above one can't help you get the expected result, please clarify which numbers in your screenshot meet those two conditions you mentioned? And in order to provide you with a suitable solution, could you please provide some sample data(exclude sensitive data) and the Fields settings of your matrix. If there are measures involved, please provide their formulas. Thank you.
If threshold value is above 3 (per month) then set highlighting
and
If threshold value is above 5 (in 3 months) then set highlightingBest Regards
Hi Anonymous ,
I created a sample pbix file(see attachment) for you, please check whether that is what you want.
1. Create a measure as below to make conditional formatting
Conditional formatting =
VAR _tab =
SUMMARIZE ( 'Table', 'Table'[date].[Month], "@qty", SUM ( 'Table'[qty] ) )
VAR _qty =
SUMX ( _tab, [@qty] )
VAR _count =
COUNTROWS ( FILTER ( _tab, [@qty] > 3 ) )
RETURN
IF (
_count > 0,
IF (
(
ISINSCOPE ( 'Table'[order] ) || ISINSCOPE ( 'Table'[item] )
|| ISINSCOPE ( 'Table'[date] )
),
IF ( _qty > 3, "red" ),
IF ( _qty > 5, "red" )
)
)
2. Configure conditional formatting
If the above one can't help you get the expected result, please clarify which numbers in your screenshot meet those two conditions you mentioned? And in order to provide you with a suitable solution, could you please provide some sample data(exclude sensitive data) and the Fields settings of your matrix. If there are measures involved, please provide their formulas. Thank you.
If threshold value is above 3 (per month) then set highlighting
and
If threshold value is above 5 (in 3 months) then set highlighting
Best Regards