MyPage is a personalized page based on your interests.The page is customized to help you to find content that matters you the most.


I'm not curious

How to draw pie chart?

Published on 10 August 18
371
0
0
Recently I came through a requirement to draw pie chart in an application. I made that application in php.
2
I searched around and find the best code for drawing pie chart.
<html>

<head>

<script type="text/javascript" src="https://www.google.com/jsapi"></script>

<script type="text/javascript">

google.load("visualization", "1", {packages:["corechart"]});

google.setOnLoadCallback(drawChart);

function drawChart() {

var data = google.visualization.arrayToDataTable([

['Task', 'Hours per Day'],

['Work', 11],

['Eat', 2],

['Commute', 2],

['Watch TV', 2],

['Sleep', 7]

]);


var options = {

title: 'My Daily Activities'

};


var chart = new google.visualization.PieChart(document.getElementById('chart_div'));

chart.draw(data, options);

}

</script>

</head>

<body>

<div id="chart_div" style="width: 900px; height: 500px;"></div>

</body>

</html>
You can change the parameters in the code and can get different kinds of results. You can also make this chart 3D.
You can get more reference over this link : Pie chart
Helpful Links:
1. https://www.devsaran.com/blog/11-best-wordpress-photo-gallery-plugins
2. https://www.gurutechnolabs.com/stunning-graphics-design-tips/
Recently I came through a requirement to draw chart in an application. I made that application in .

2

I searched around and find the best code for drawing pie chart.

You can change the parameters in the code and can get different kinds of results. You can also make this chart 3D.

You can get more reference over this link : Pie chart

Helpful Links:

1. https://www.devsaran.com/blog/11-best-wordpress-photo-gallery-plugins2. https://www.gurutechnolabs.com/stunning-graphics-design-tips/

This blog is listed under Development & Implementations Community

Related Posts:
Post a Comment

Please notify me the replies via email.

Important:
  • We hope the conversations that take place on MyTechLogy.com will be constructive and thought-provoking.
  • To ensure the quality of the discussion, our moderators may review/edit the comments for clarity and relevance.
  • Comments that are promotional, mean-spirited, or off-topic may be deleted per the moderators' judgment.
You may also be interested in
 
Awards & Accolades for MyTechLogy
Winner of
REDHERRING
Top 100 Asia
Finalist at SiTF Awards 2014 under the category Best Social & Community Product
Finalist at HR Vendor of the Year 2015 Awards under the category Best Learning Management System
Finalist at HR Vendor of the Year 2015 Awards under the category Best Talent Management Software
Hidden Image Url

Back to Top