-
Notifications
You must be signed in to change notification settings - Fork 197
Description
The naive implementation does not work because it has banding issues due to quantization on the date axis.
In the example below we have monthly data. Even with the correct width (corresponding to the number of different months), some months are rounded down to the pixel on their left hand side. This happens because the rounding in InterpolateNone is made by flooring the date divided by the average length of a month. (And months expressed in milliseconds are not uniform.)
An easy way to fix this would be to allow changing the interpolator to use Math.round instead of Math.floor:
We could call this interpolator: "round". However we might want more control on x vs y, so maybe we need more options. It would also be nice to auto-apply rounding when the dimension is temporal?
Notebook exploration: https://observablehq.com/@observablehq/plot-raster-dates-2351