PMSI-AlignAlytics / dimple

An object-oriented API for business analytics
Other
2.73k stars 556 forks source link

tool tips #216

Open dss010101 opened 8 years ago

dss010101 commented 8 years ago

This example doesn't quite do what i want. http://jsfiddle.net/6n5r6vyb/13/

It looks like because of the first parameter to addSeries, the chart is rendering each data point as a separate series. What i want to do is draw a line series, but have the additional info appear in the tool tip only (i.e. not used for grouping or categorization, but simply additional info).

Any help would be appreciated.

johnkiernander commented 8 years ago

Unfortunately you can't add extra details to a line chart tooltip in that way because (as you rightly concluded) it causes the line to be split by each value. The best approach instead is to use a custom tooltip to pick the values from the data for the relevant point. Here's an updated fiddle:

http://jsfiddle.net/6n5r6vyb/14/

dss010101 commented 8 years ago

That works! Thank you!