I just started testing various features available in a jQuery graphical plugin called Flot. I seem to be getting an error trying to determine at what point I clicked. This fiddle ( http://jsfiddle.net/devin85/BxjgV/ ) contains my initial attempt to combine the bubble chart with a standard line chart. Below is the method where ew detects a click, however it always seems to identify point 11 in the series.
$("#placeholder").bind("plotclick", function (event, pos, item) { console.log(item) if (item) { $("#clickdata").text("You clicked point " + item.dataIndex + " in " + item.series.label + "."); plot.highlight(item.series, item.datapoint); } });
Can someone please show me why the point pressed is always the end point in the series?
Thanks for the help!
source share