Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [["Year","accept","error","total"],[{"v":0,"f":"20.09.2018"},1,3,4],
- [{"v":1,"f":"21.09.2018"},4,5,9],[{"v":2,"f":"22.09.2018"},0,7,7],
- [{"v":3,"f":"24.09.2018"},14,14,28],[{"v":4,"f":"25.09.2018"},2,2,4],
- [{"v":5,"f":"26.09.2018"},6,16,22]]
- function drawChart(chart_id, chart_title, chart_data) {
- var data = google.visualization.arrayToDataTable(
- chart_data
- );
- var options = {
- title: chart_title,
- hAxis: {
- title: 'Datum',
- titleTextStyle: {color: '#333'}},
- vAxis: {minValue: 0},
- trendlines: {
- 0: {
- type: 'polynomial',
- degree: 3,
- },
- 1:{
- type: 'polynomial',
- degree: 3,
- },
- 2:{
- type: 'polynomial',
- degree: 3,
- } } // Draw a trendline for data series 0.
- };
- var chart = new google.visualization.AreaChart(document.getElementById(chart_id));
- chart.draw(data, options);
- }
Add Comment
Please, Sign In to add comment