The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi!
I am making a donut chart to go alongside a risk matrix. The risk matrix is colour coded based off the combined score from the 'Inherent Impact' and 'Inherent Liklihood' of the risk. I wanted to make a pie chart with the same colours. I created a new column with values of the multiplied 'Inherent Impact' and 'Inherent Liklihood' columns, but I'm a bit stuck from here!
My issue is probably that I'm trying to create a pie chart with a single column, but I thought there would be some conditional formatting option for colour, such as 'If value is >2 and <25, "#93D150' so I could divide up the donut chart but I can't find anything like that!
This is the risk matrix I have:
This is the 'total risk' colum I have:
and this is the sad little donut chart I have produced so far:
I would be really grateful if anyone had any suggestions!
Solved! Go to Solution.
Hi @TG242891Reading ,
Yeah, this is frustrating but I'll give you the real deal. Power BI donut charts don't have conditional formatting built-in like other visuals do.
Here's what you actually need to do:
Step 1: Create risk categories first Make a calculated column to group your scores:
Risk Level = IF([Total Risk] <= 6, "Low Risk", IF([Total Risk] <= 15, "Medium Risk", IF([Total Risk] <= 25, "High Risk", "Critical Risk")))
Step 2: Use the workaround
Step 3: Manual color override Once you switch to donut, the conditional formatting disappears, but the colors stick. You can then manually adjust individual slice colors in the format pane if needed.
Alternative: Just create the donut chart normally with Risk Level categories and manually set each slice color in the format pane. Less fancy but gets the job done.
The conditional formatting trick only works by going through bar chart first - it's a known limitation that Microsoft hasn't fixed.
If my response resolved your query, kindly mark it as the Accepted Solution to assist others. Additionally, I would be grateful for a 'Kudos' if you found my response helpful.
This response was assisted by AI for translation and formatting purposes.
Your donut chart isn't subdivided so you get to choose a single color only. Create a column that categorizes Total Risk and use that as Legend. You can then assign a color for each of the category in Slices
Hi @TG242891Reading ,
Yeah, this is frustrating but I'll give you the real deal. Power BI donut charts don't have conditional formatting built-in like other visuals do.
Here's what you actually need to do:
Step 1: Create risk categories first Make a calculated column to group your scores:
Risk Level = IF([Total Risk] <= 6, "Low Risk", IF([Total Risk] <= 15, "Medium Risk", IF([Total Risk] <= 25, "High Risk", "Critical Risk")))
Step 2: Use the workaround
Step 3: Manual color override Once you switch to donut, the conditional formatting disappears, but the colors stick. You can then manually adjust individual slice colors in the format pane if needed.
Alternative: Just create the donut chart normally with Risk Level categories and manually set each slice color in the format pane. Less fancy but gets the job done.
The conditional formatting trick only works by going through bar chart first - it's a known limitation that Microsoft hasn't fixed.
If my response resolved your query, kindly mark it as the Accepted Solution to assist others. Additionally, I would be grateful for a 'Kudos' if you found my response helpful.
This response was assisted by AI for translation and formatting purposes.
Yes!!
Thank you so much, that's brilliant~
You explained it so simply as well, thank you!
You're very welcome! Really glad that worked out for you.
The bar chart workaround is definitely one of those "Power BI tricks" you pick up over time - not the most elegant solution but it gets the job done when the direct approach doesn't work.
User | Count |
---|---|
81 | |
78 | |
37 | |
34 | |
31 |
User | Count |
---|---|
93 | |
81 | |
60 | |
49 | |
49 |