Forum Discussion
javaroni
1 year agoRegular Visitor
Sankey Chart - Deneb - Measure Problem
Hi, i´m using Deneb to create a sankey chart. Everything is working until i starting to use a measure as value. When i use a column as value, it´s works But when a using a sum measure and n...
- 1 year ago
That's a weird input format 🙂 Have to see how this can be converted.
As for the texts overlapping - there's not much you can do apart from mimicking the stacking logic that is used for the boxes. you would need to probe the frame boundaries for the rendered text, see if any x values overlap, and then push the y origin up for an amount that clears the conflict. But this may cascade when you have lots of small boxes with long text.
javaroni
1 year agoRegular Visitor
Tks for the replie lbendlin.
Can you give a an example for the overlap solution =)?
lbendlin
1 year agoSuper User
Here's something I did recently (sorry for the blurring)
I used a sorted window for the stacking.
{
"window": [
{
"op": "sum",
"field": "CU (s)",
"as": "cum_total"
}
],
"sort": [
{
"field": "CU (s)",
"order": "descending"
}
],
"frame": [null, 0]
},
{
"calculate": "datum.cum_total - datum['CU (s)'] + 2", "as": "bottomedge"
}
"bottomedge" is the derived y value for each bar's rendering box.
- javaroni1 year agoRegular Visitor
That´s Great
Thank you for the help