feat: Support multiple y values per x value on discrete scatterplot
The following discussion from !631 (merged) should be addressed:
-
@mikegreiling started a discussion: (+1 comment) Could you update the example to display multiple points for at least some of the days? That's what differentiates the scatter chart from a basic line chart so I think it would be beneficial to show it in the example.
If we're going to display multiple items on the y axis for the same x axis value, we'd need refactor the computation of the tooltip position (which is currently tied to the x axis).
Chart data including multiple items per x value could be passed in the following format (see 22 May
):
chartData: [
{
data: [
['19 May', 6.95],
['20 May', 7.58],
['21 May', 8.81],
['22 May', 8.33],
['22 May', 10.04],
['23 May', 9.96],
['24 May', 7.24],
['25 May', 4.26],
]
}
]
Edited by Martin Wortschack