Get certified for free when you join Fabric Data Days 2026 and dive into Fabric, Power BI, SQL, AI, and other essential data skills.
Join nowTry your skills in the Power BI Dataviz World Championship! Round one ends June 26. Join now
I've created a series of rules to enable a RAG traffic system to track performance against targets. The tolerance is set at 10%, with the folllowing conditions:
Currently, I calculate this manually. In the example below, the target is 83 and I worked out the 10% tolerance and adjusted the thresholds accordingly. However, the target changes each month so having the current set up isn't efficient, because I have to recalculate and update the thresholds every time the target changes.
What I’d like to do is define the RAG rules dynamically using percentage differences, rather than fixed values. So instead of rules like:
If value >= 0 and < 74.7, then red
I want something more like:
If the actual is more than 10% below the target, then red.
Solved! Go to Solution.
Hi @eladumitrascu Try this please
Create a calculated Column or Measure
Formula :
RAGStatus =
IF(
[Actual] >= [Target],
"Green",
IF(
[Actual] >= [Target] * 0.9,
"Amber",
"Red"
)
)
Hi @eladumitrascu Try this please
Create a calculated Column or Measure
Formula :
RAGStatus =
IF(
[Actual] >= [Target],
"Green",
IF(
[Actual] >= [Target] * 0.9,
"Amber",
"Red"
)
)
Hi, thanks for this. Would this calculated measure work for different metrics, or would I need to create an individual measure for each specific metric that I want to compare against targets? Thanks
Hi @eladumitrascu Try this:
RAG Status =
VAR Target = [Target]
VAR Actual = [Actual]
VAR Tolerance = 0.1 * Target
RETURN
SWITCH(
TRUE(),
Actual >= Target, "Green",
Actual >= Target - Tolerance, "Amber",
"Red"
)
Hope this helps!!
If this solved your problem, please accept it as a solution and a kudos!!
Best Regards,
Shahariar Hafiz
| User | Count |
|---|---|
| 23 | |
| 20 | |
| 19 | |
| 19 | |
| 10 |
| User | Count |
|---|---|
| 54 | |
| 53 | |
| 41 | |
| 37 | |
| 32 |