Open
Description
openedon Sep 3, 2019
The facet sort order works as expected with non-aggregated data (editor):
{
"data": {"url": "data/cars.json"},
"mark": "bar",
"encoding": {
"row": {
"type": "nominal",
"field": "Origin",
"sort": ["Japan", "Europe", "USA"]
},
"x": {"type": "quantitative", "field": "Horsepower"}
}
}
But if an aggregation is added to the x-axis, the order is no longer respected (editor):
{
"data": {"url": "data/cars.json"},
"mark": "bar",
"encoding": {
"row": {
"type": "nominal",
"field": "Origin",
"sort": ["Japan", "Europe", "USA"]
},
"x": {"type": "quantitative", "field": "Horsepower", "aggregate": "mean"}
}
}
Reported in vega/altair#1683
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment