JQuery.Highcharts.js plot graph of pie chart _jquery

Source: Internet
Author: User

In the data statistics and analysis business, sometimes the customer needs to be in a chart of the histogram, pie chart, graphs are reflected, that is, you can see the specific data from the histogram, but also from the graph to see the trend of change, as well as from the pie chart to see the proportion of each part of the data. Highcharts can easily achieve the effect of three graphs in unity.

Copy Code code as follows:

var chart;
$ (document). Ready (function () {
Chart = new Highcharts.chart ({
Chart: {
Renderto: ' Container ',
Defaultseriestype: ' Area '
},
Title: {
Text: ' Historic and estimated worldwide Population growth by Region '
},
Subtitle: {
Text: ' Source:Wikipedia.org '
},
Xaxis: {
Categories: [' 1750 ', ' 1800 ', ' 1850 ', ' 1900 ', ' 1950 ', ' 1999 ', ' 2050 '],
Tickmarkplacement: ' On ',
Title: {
Enabled:false
}
},
YAxis: {
Title: {
Text: ' Billions '
},
Labels: {
Formatter:function () {
return this.value/1000;
}
}
},
ToolTip: {
Formatter:function () {
Return ' +
This.x + ': ' + highcharts.numberformat (this.y, 0, ', ') + ' millions ';
}
},
Plotoptions: {
Area: {
Stacking: ' Normal ',
LineColor: ' #666666 ',
Linewidth:1,
Marker: {
Linewidth:1,
LineColor: ' #666666 '
}
}
},
Series: [{
Name: ' Asia ',
Data: [502, 635, 809, 947, 1402, 3634, 5268]
}, {
Name: ' Africa ',
Data: [106, 107, 111, 133, 221, 767, 1766]
}, {
Name: ' Europe ',
Data: [163, 203, 276, 408, 547, 729, 628]
}, {
Name: ' America ',
Data: [18, 31, 54, 156, 339, 818, 1201]
}, {
Name: ' Oceania ',
Data: [2, 2, 2, 6, 13, 30, 46]
}]
});
});

That's all we have in this article, and I hope it helps to draw a pie chart graph with jquery.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.