vega-lite
vega-lite copied to clipboard
Can't encode color with scale resolved as y="independent"
If I have a bar chart faceted by row, and encoded by color, then:
- If I don't resolve the y scale, then the colors work fine.
- If I resolve the y scale as "independent", then the entire chart disappears. I see an error
[Error] datum is not defined
in the logs. I want to be able to resolve the y as independent, because I only want to show some y values within each row. If I remove the color encoding, then resolving y as independent works fine.
I am looking for something like this working plot
- [x] Check for duplicate issues. Please file separate requests as separate issues.
- [x] Describe how to reproduce the bug.
- [x] Use the latest versions of Vega and Vega-Lite. (5.15.0 that vega-editor uses)
repro: try uncommenting out the resolve scale line. Open the Chart in the Vega Editor
Hi @NickCrews,
Not sure why the auto-scale not work but if you assign height value, it works fine.
For the [Error] datum is not defined
error log, if you re-run again, the error will disappear
"width": 300,
"height":60
Open the Chart in the Vega Editor
(adjust width so that the Coauthor-else can be shown)