Drilldown multiple levels Highchart

前端 未结 6 2085
清歌不尽
清歌不尽 2020-12-05 05:19

We like to Drilldown on multiple levels in Highchart. Is there already an example in Highchart?

Currently used code:

$(div).highchar         


        
6条回答
  •  死守一世寂寞
    2020-12-05 05:37

    Here is an example that preserves the names on the axis. (Drilldown works on "Animals" > "Mammals")

    Drilldown options looks like this:

    drilldown: {
      series: [{
        id: 'animals',
        data: [{
            name: 'Mammals',
            y: 4,
            drilldown: 'mammals'
          },
          ['Reptiles', 2],
          ['Vertebrates', 1]
        ]
      }, {
        id: 'mammals',
        data: [['Cats', 3], ['Dogs', 2], ['Platypus', 1]]
      },
      ...
    

    http://jsfiddle.net/vcsqnr2z/

提交回复
热议问题