No Description Available
0
Google Charts allow us to create decent looking charts. It is a JavaScript library that is embedded with many pre-built charts like bar charts, calendar charts, area charts, geo charts, pie charts, and many other multi-functional charts.
onex
google.charts.load('current', {'packages':['corechart']}); google.charts.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('piechart')); chart.draw(data, options); // 3d pieChart 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', is3D:true }; var chart = new google.visualization.PieChart(document.getElementById('piechart3d')); chart.draw(data, options); }
<div class="row"> <div class="col-md-6"> <div id="piechart" style="width: 900px; height: 500px;"></div> </div> <div class="col-md-6"> <div id="piechart3d" style="width: 900px; height: 500px;"></div> </div> </div>