Highcharts:为钻取添加额外数据

据我所知,钻取数据格式是这样的:

data: [['foo1', 2], ['foo2', 3], ['foo3', 2]] 

我实际上成功地向每个数组添加数据,如下所示:

  data: [['foo1', 2, 111], ['foo2', 3, 222], ['foo3', 2, 333]] 

但是,展示它给我带来了麻烦。 据我所知,对于工具提示格式化程序,使用this.point.name,this.point.y,this.x或this.percentage访问数据。 如何在这一点上检索额外的数据呢?

切换到使用点对象而不是数组的数据。

  drilldown: { series: [{ id: 'animals', data: [{name: 'Cats', y: 4, otherValue: 100}, 

在格式化程序中,您的额外值将在:

 this.point.otherValue 

小提琴的例子 。