Forum Discussion
Power BI Matrix
BIswajit_Das
I created a measure for Conditional Formatting called CF. I also made a table to pick the colors for items with colors ranging from 1 to 10. You may modify this table as necessary. Here is the measure.
File is attached below.
CF =
VAR __Item = SELECTEDVALUE( 'Table'[ITEM] )
VAR __T = ADDCOLUMNS( ALLSELECTED( 'Table'[ITEM] ) , "@Max" , [Count] )
VAR __Max1 = MAXX( __T , [@Max] )
VAR __Max2 = MAXX( FILTER( __T , [@Max] < __Max1 ) , [@Max] )
VAR __Gap = __Max1 - __Max2
VAR __Color = LOOKUPVALUE( Colors[Color] , Colors[Item] , __Item , Colors[Code] , __Gap )
RETURN
IF( [Count] = __Max1 , __Color)
Hello Fowmy Thanks for the content
but
I want to color according to the Gap Group but when I am modifing the content it's not working
Using DAX :
- Fowmy2 years agoSuper User
BIswajit_Das
Sorry, I didn't understand the issue that you are facing. Please elaborate.- BIswajit_Das2 years agoImpactful Individual
Hello Fowmy
I want to Calculate the percentage of MAX value and the 2ND MAX value
Then I want to calculated their Percentage Gap
Then I want to Group them by 0-5%, 6-10%, 11-15%
And In the End I want to Check The Max Item And the Group and Apply color according to the Results..- Fowmy2 years agoSuper User
BIswajit_Das
Your initial inquiry did not align with this requirement, as I understand it. The solution I presented was tailored to the information provided in the original question. Given that it meets the expectations for that specific query, I recommend accepting my response as the solution. For any further inquiries, please initiate a new question with a clear explanation and desired outcome for a more accurate response.