When I hover on the lines on the cumulative line chart I get a tooltip message x value at some y time. I want to edit this message and add more content.
Since in my values array I have json containing {X:x, Y:y, Z:z, Dt:date} I wish to show a custom message listing X/Y/Z at date.
I'm using nvd3 veraion 1.1.15b.
Calling
.tooltip()
didn't work for me, but calling.tooltipContent()
did, as in the following code:As Andrei points out above, the
e
parameter provides access to the raw values so you can format them, rather than working withy
which is already formatted text. Hope this helps!If you have not found a proper solution yet, here you try this -
Hope it helps.