简体   繁体   中英

HighCharts not displaying all the categories

I'm using HighCharts library for displaying charts for my project. I've modified the chart a bit. I have kind of combined these two charts http://www.highcharts.com/demo/combo-multi-axes and http://www.highcharts.com/demo/column-rotated-labels together to get the desired chart. But the problem now is that when the charts are displayed. All the categories are not displayed and only the first

You appear to have several series, each with only one data point. That will, by default, only show one category, because it is grouping them (the first point of each series in the first category, the second point of each series in the second category, etc).

I would suggest making this one series - it is overkill and adds unnecessary complications to make each data point a series.

Alternatively, if you're stuck to the idea of multiple series, you can add grouping: false to your plotOptions, which will over ride the default behavior.

Reference:

UPDATE:

I forgot to add that you need to include an x value for each data point as well.

Example:

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM