Forum Discussion
Matrix Table - Formatting
- 1 year ago
You will need a measure that picksup the previous year's value and compare that with the current and build conditional formatting on to of it.
Below is just a sample conditional formatting measure to be used as field. Actual measure will vary depending on the structure of your model.
conditinal formatting = VAR _ly = CALCULATE ( [aggregation], FILTER ( ALL ( 'table'[year] ), 'table'[year] = MAX ( 'table'[year] ) - 1 ) ) RETURN IF ( [aggregation] <> _ly, "yellow" )Please refer to this sticky post on how to get a better answer - https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523
You will need a measure that picksup the previous year's value and compare that with the current and build conditional formatting on to of it.
Below is just a sample conditional formatting measure to be used as field. Actual measure will vary depending on the structure of your model.
conditinal formatting =
VAR _ly =
CALCULATE (
[aggregation],
FILTER ( ALL ( 'table'[year] ), 'table'[year] = MAX ( 'table'[year] ) - 1 )
)
RETURN
IF ( [aggregation] <> _ly, "yellow" )
Please refer to this sticky post on how to get a better answer - https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523
- kcdavi011 year agoFrequent Visitor
Hi all,
Hope all is well! Thanks a bunch for providing!! 😄 I had a feeling it was some sort of measure/column to implement lol
I attempted applying the Measure structure provided but think this is where my PBI limitations start to show haha
I entered the below Formula but Im not exactly getting the result I was looking for. Could I have entered the formula incorrectly? (with conditional formatting applied)
conditinal formatting2 =
VAR _lys2 =
CALCULATE (MAX(
'RPNs-2'[Value - Copy]),
FILTER(ALL('RPNs-2'[RPN Year]),'RPNs-2'[RPN Year]= MAX('RPNs-2'[RPN Year] )
))
VAR _ly2 =
CALCULATE (MAX(
'RPNs-2'[Value - Copy]),
FILTER(ALL('RPNs-2'[RPN Year]),'RPNs-2'[RPN Year]= (MAX ( 'RPNs-2'[RPN Year] ) - 1 ) )
)
RETURN
IF ( _lys2 > _ly2, "yellow" )Heres a lil sample of the dataset Im working with for consideration:
Thanks in advance again for any guidance you can provide!!