You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi @declann, unfortunately you're running up against a current limitation of vgplot. The Fixed domain setting fixes the domain based on the first values it sees. For many mark types we hand queried data over to Observable Plot and then use the domain settings it chooses based on the chart attributes.
To get the "full" domain we need to get the full range of values from the database. Fortunately, this is something you can also do yourself if you're using the JavaScript API. Though more cumbersome, you can query DuckDB (e.g., using coordinator.query()) to get value ranges and determine a hard-wired domain of your own to pass into your chart spec.
For more automatic support (inc. from YAML/JSON specs), we'd need to extend vgplot to perform this logic behind the scenes. I'll interpret this issue as a feature request for this support.
I'm setting selection defaults through menu inputs that have
value
s set.Fixed
scale domain setting I'm using behaves as advertised in that the scale domain doesn't change on subsequent data updates.But, I expected the domain calculation to include all data.
It's filtered to the default selection however. It might be ambiguous but this seems like a bug to me?
To reproduce:
xDomain: Fixed
Here is a gif of the result:
Screencast.from.2024-10-28.20-24-50.webm
The domain is fixed but whenever I select All, then data is truncated.
When I fix the domain with no default selection I see a fuller representation:
Should
Fixed
give this range, independent of the default selection?The text was updated successfully, but these errors were encountered: