Accepted answer

If you want to attach additional data to points in a series you can initialize the points that need additional data as objects instead of arrays/ints. For example, with your code you could do:

series: [{
    name: 'Song Plays',
    data: [
       {x:'song_name1', y:123, songid:'song_id_1'},
       {x:'song_name2', y:234, songid:'song_id_2'}

You can then get it from the point on click as event.point.songid. See this JSFiddle demo using point click and tooltip.

Note that in many cases x in the object will not be required. It is often automatic and sequential.


You can try


Updated fiddle:

Or this:


Related Query

More Query from same tag