born2net
born2net

Reputation: 24953

High charts, providing data for xAxis instead of Series

As you can see in example:

http://jsfiddle.net/gh/get/jquery/1.9.1/highslide-software/highcharts.com/tree/master/samples/highcharts/demo/bar-stacked/

plotOptions: {
            series: {
                stacking: 'normal'
            }
        },

the data is provided in series for John, Jane and Joe in series. Instead, what I would like to do, is just provide the data for Apples', 'Oranges', 'Pears', 'Grapes', 'Bananas' such as:

Apples: 1,2,3,4,5 (will all display on the first bar) Oranges: 10,20,30,40,50 (will all display on the second bar) etc...

So I can provide the data PER BAR instead of across...

is it possible?

Thanks for reading,

Sean.

Upvotes: 0

Views: 48

Answers (1)

Rahul Gupta
Rahul Gupta

Reputation: 10141

I think what you want is this: DEMO;

To obtain such an output chart instead of a stacked chart, just comment out the code section show belwo like:

plotOptions: {
                /*series: {
                    stacking: 'normal'
                }*/
            },

Commenting out the above section of code will convert a stacked bar chart into a normal bar chart with individual bars for the categories.

Upvotes: 0

Related Questions