0

consider the link http://jsfiddle.net/5D5eD/24/. In this example if there is one more field in data array like

[2,2,"a"],
[3,3,"b"],
[4,4,"c"],
[5, 4,"d"],
[5.5, 5,"e"],
[6, 6,"f"],
.
.
.

a,b,c, is a character string, what code should add to the program so as to obtain the character string on mouse-hovering at respective datapoints on chart, that is on hovering the mouse near [2,2] it should show a and near [3,3] it should show b..... so on. How to do this ?

user3438326
  • 89
  • 2
  • 10
  • possible duplicate of [D3: show data on mouseover of circle](http://stackoverflow.com/questions/10805184/d3-show-data-on-mouseover-of-circle) – Lars Kotthoff Apr 01 '14 at 17:32

1 Answers1

1

http://jsfiddle.net/5D5eD/25/

I used jquery and jqueryui.
the code I added was:

.attr('class', 'dotip')
.attr('title', function (d, i) { return d[2] })

at line 92
AND

$(".dotip").tooltip();

At the bottom

2pha
  • 9,798
  • 2
  • 29
  • 43