-
-
Notifications
You must be signed in to change notification settings - Fork 686
Open
Labels
Bug 🐛Help WantedGood tasks for contributors (try https://github.com/vega/vega-lite/issues/1486 first)Good tasks for contributors (try https://github.com/vega/vega-lite/issues/1486 first)
Description
Bug Description
When aggregating a field, groups alphabetically prior to a group where the values for the field are all NULL will not render.
In this example, denials in GroupA is always amount=NULL and the categories aaa, charges do not render for that group. Everything works fine for GroupB presumably because denials has at least one non-NULL entry.
{
"$schema": "https://vega.github.io/schema/vega-lite/v6.json",
"description": "Bug: categories alphabetically prior to an all-NULL category will not render",
"data": {
"values": [
{"grouping": "GroupA", "type": "aaa", "amount": 100},
{"grouping": "GroupA", "type": "charges", "amount": 100},
{"grouping": "GroupA", "type": "denials", "amount": null},
{"grouping": "GroupA", "type": "denials", "amount": null},
{"grouping": "GroupA", "type": "yyy", "amount": 100},
{"grouping": "GroupA", "type": "zzz", "amount": 100},
{"grouping": "GroupB", "type": "aaa", "amount": 100},
{"grouping": "GroupB", "type": "charges", "amount": 100},
{"grouping": "GroupB", "type": "denials", "amount": 100},
{"grouping": "GroupB", "type": "denials", "amount": null},
{"grouping": "GroupB", "type": "yyy", "amount": 100},
{"grouping": "GroupB", "type": "zzz", "amount": 100}
]
},
"mark": {"type": "bar"},
"encoding": {
"x": {
"field": "grouping",
"type": "nominal",
"title": "Group"
},
"y": {
"aggregate": "sum",
"field": "amount",
"type": "quantitative",
"title": "Sum of Amount"
},
"color": {
"field": "type",
"type": "nominal"
}
}
}- I checked for duplicate issues.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Bug 🐛Help WantedGood tasks for contributors (try https://github.com/vega/vega-lite/issues/1486 first)Good tasks for contributors (try https://github.com/vega/vega-lite/issues/1486 first)