Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!
Hello,
The community helped me create a waterfall chart using DAX at the following link:
https://community.fabric.microsoft.com/t5/Desktop/Waterfall-Challenge/m-p/4942137#M1456881
The data I’m using is as follows:
| 1 | Budget NPAT | 4,261,532 |
| 2 | Gross Margin | 2,733,696 |
| 3 | Variable Costs | -280,573 |
| 4 | 3rd Party Cost Recovery | -435,951 |
| 5 | Other Income | 32,571 |
| 6 | Fixed Costs | 1,324,187 |
| 7 | Support Cost | 738,378 |
| 8 | Depreciation | -664,124 |
| 9 | Bad Debt Provision | 799,823 |
| 10 | Finance Exp & Inc | -1,537,797 |
| 11 | Income Tax | -637,201 |
| 12 | Actual NPAT | 6,334,541 |
The challenges I’m facing:
I want the data labels to appear above the boxes.
Can the Actual NPAT start from zero? It’s very high as shown in the attached image.
want to set the color of Actual NPAT to #A4D233 and the color of Budget NPAT to #389BBD.
Hi @majid154a,
Since you’re using Deneb (Vega-Lite), all three requirements can be handled directly in the JSON spec.
Add a text layer and shift it upward using dy:
{
"mark": {
"type": "text",
"dy": -10,
"fontWeight": "bold"
},
"encoding": {
"text": {"field": "value", "type": "quantitative"},
"color": {"value": "black"}
}
}
If labels are still inside the bars, increase the negative dy (e.g., -12 or -15).
2. Make “Actual NPAT” start from zero
Override the starting position for that category using a calculated field:
{
"calculate": "datum.cat === 'Actual NPAT' ? 0 : datum.StartValue",
"as": "AdjustedStart"
}
Then use:
"y": {"field": "AdjustedStart"},
"y2": {"field": "EndValue"}
This forces Actual NPAT (Net Profit After Tax) to behave as a total bar starting from zero instead of continuing the running total.
Use conditional color encoding:
"color": {
"condition": [
{
"test": "datum.cat === 'Actual NPAT'",
"value": "#A4D233"
},
{
"test": "datum.cat === 'Budget NPAT'",
"value": "#389BBD"
}
],
"value": "#D3D3D3"
}
Actual NPAT → #A4D233
Budget NPAT → #389BBD
Others → default gray
Summary Use a text layer with negative dy for labels above bars Override the start value for Actual NPAT with a calculate transform Apply conditional color encoding for category-specific colors That should resolve all three requirements cleanly within Deneb.
Vote for your favorite vizzies from the Power BI World Championship submissions!
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
Check out the January 2026 Power BI update to learn about new features.