score:0

you are doing it wrong. you don't need a loop for that purpose. if you only want one point/data object you can use this.

looping through points is for check every points that are vertically aligned (same x).

on the link for the documentation of the formatter you have another link that goes here:

http://jsfiddle.net/gh/get/jquery/1.7.2/highslide-software/highcharts.com/tree/master/samples/highcharts/tooltip/formatter-simple/

you can see the example and i think this is what you are trying to do.

score:4

instead of using shared tooltip, try with default one: http://jsfiddle.net/2v0ya6d5/1/

code:

    tooltip: {
        formatter: function () { 
            var series = this.point.series.chart.series, // get all series 
                index = this.point.series.xdata.indexof(this.point.x), // get index
                str = '';

            // default tooltip
            $.each(series, function(i, s) { 
                str += 'the value for <b>' + s.data[index].category +
                '</b> is <b>' + s.data[index].y + '</b><br>'
            });

            // "this" refers to the selected point:
            str+= 'selected point? x: ' + this.x + ' y: ' + this.y;

            return str;
        }
    },

Related Query

More Query from same tag