Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

157
Vistas
Highcharts get if data is currently beeing grouped with multiple series

I want to determine wether data grouping is currently beeing applied to a series or not after the user zooms in into the graph.
When there is only one series inside the graph it works just fine with the approach i found by using the hasGroupedData, which returns true if data is grouped and undefined if it's not.

chart.series[0].hasGroupedData

However, if there are more than one series inside the graph this always returns true once the data grouping has been applied once on the series so there is no way for me to know anymore if the data is beeing grouped or not.

Data Grouping

The same behaviour is with the normal Highcharts chart as well as the Highstock stockchart, which I want to use.
I am out of ideas how else i could determine if the series is beeing grouped or not so any help would be appreciated.

Example code: https://jsfiddle.net/Itsearnest/ho0a4zw9/

var chart = Highcharts.stockChart('container', {
    chart: {
        zoomType: "x"
    },
  navigator:{
    enabled:false
  },
  yAxis:[{},{}],
  xAxis:{
    events:{
        afterSetExtremes: (event) => {
        var info = document.getElementById("info");
        info.innerHTML = "";
        chart.series.forEach((elem) =>{
            info.innerHTML += ("Data grouped for " + elem.name +": " + elem.hasGroupedData) + "<br>";
        });
      }
    }
  },
  series: [{
    data: Array.from({length: 50000}, () => Math.floor(Math.random() * 500))
  }]
});

document.getElementById("add").onclick  = (event) => {
    var base = Math.floor(Math.random()*1000);
    chart.addSeries({
        data: Array.from({length: 50000}, () => base + Math.floor(Math.random() * 500))
    });
};

Edit. It turns out it is a bug in Version 10.0.0. After downgrading to 9.1.2 it works as intended (https://github.com/highcharts/highcharts/issues/17141)

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda