Thank you @Fil. I’m perfectly fine with scaleLinear. I’m just curios about how decimal values in the range are mapped to screen pixels, since they are finite and non-fractional. A very low-level question.
Of course in many applications, that number is used to define pixel positions, for example by setting an attribute on the DOM, maybe for a svg circle like so:
d3.select(“circle”).attr(“cx”, scale(value))
In that case, if scale(value) has returned a number such as 123.45678901, that number is passed as-is to the DOM, resulting in a circle with a cx attribute equal to “123.45678901”.
And then it is the browser that colors the pixels with that information, using anti-aliasing if the values do not exactly match pixels.