I have a plot using Observable Plot.dot
with x
, y
, and symbol
channels.
Live example at:
Using the tip
mark option, the tooltips display the labels and values for the x
, y
, and symbol
channels. For example, this:
{x: 'a', y: 'b', symbol: 'c', tip: true}
gives me tooltips like this (which is what I want):
My X 1
My Y 1
My Symbol 1
However, if I explicitly create a Plot.tip
then the tooltips display the labels and values for x
and y
, but not the symbol
channel. For example, this:
Plot.pointer({x: 'a', y: 'b', symbol: 'c'})
gives me tooltips like this (which is not what I want):
My X 1
My Y 1
If I try to add the symbol channel via channels
like this:
Plot.pointer({x: 'a', y: 'b', channels: {symbol: 'c'}})
then I get tooltips like this (with the label for symbol
being ignored, which is also not what I want):
c 1
My X 1
My Y 1
As far as I understand it, in order to set the maxRadius
for Plot.pointer
I need to use Plot.tip
instead of the tip
mark option. But how do I do that while preserving the information and formatting in the tooltip?
Thanks,
Adam