Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I'm trying to show how long something takes in the hh:mm:ss time format on a clustered bar chart. In order for me to convert my minutes from a decimal format to the hh:mm:ss format I had to convert the value to a text string. Unfortunately now the only place Power Bi desktop is allowing my to put the text is on the tooltips but I want to show it as a data label on the bar chart. Is that even possible? Any help would be greatly appreciated.
You likely need to use a low-code visual like Deneb to add text labels to your chart. Here is an example. In my case, I added 3 similar fields to the visual (Category, Value as a decimal, and DurationText as text). JSON code from the visual is also provided below.
Declarative Visualization in Power BI | Deneb (deneb-viz.github.io)
{
"data": {"name": "dataset"},
"layer": [
{
"mark": {
"type": "bar",
"tooltip": true
}
},
{
"mark": {
"type": "text",
"dy": 10,
"color": "white"
},
"encoding": {
"text": {
"field": "DurationText"
}
}
}
],
"encoding": {
"x": {
"field": "Category",
"type": "nominal"
},
"y": {
"field": "Value",
"type": "quantitative"
}
}
}
Pat
Is that available through the "Get more visuals" section of Power Bi? If so I might have just overlooked it. Do you have the name?
I think there is a custom bar chart visual that lets you put a custom label above the total label.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
105 | |
105 | |
88 | |
73 | |
66 |
User | Count |
---|---|
122 | |
112 | |
98 | |
79 | |
72 |