I have a bar chart created with Deneb, which I originally sorted by a DAX measure ("Measure1").
After I added a new mark to show data labels, the chart is not sorted correctly anymore.
Why is this happening?
{
"title": {"text": "Simple Bar chart - labels", "fontSize": 14, "anchor": "start", "align": "left"},
"data": {"name": "dataset"},
"encoding": {
"y": {
"field": "Site Name",
"type": "nominal",
"sort": {"field": "Measure1", "order": "ascending"}
},
"x": {
"field": "Measure1",
"type": "quantitative"}
},
"layer": [
{
"mark":
{"type": "bar",
"color": "pink"}
},
{
"mark":
{"type": "text",
"color": "black",
"align": "left",
"dx": 6
},
"encoding": {
"text": {"field": "Measure1",
"type": "quantitative"} }
}
]
}
I'd like the bar chart to be sorted by "Measure1" instead of "Site Name"