Aaron log/Test Financials 01: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
<html><script type="text/javascript" src="// | <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 = new google.visualization.DataTable(); | |||
data.addColumn('string', 'Task'); | |||
data.addColumn('number', 'Hours per Day'); | |||
data.addRows([ | |||
['Work', 11], | |||
['Eat', 2], | |||
['Commute', 2], | |||
['Watch TV', 2], | |||
['Sleep', 7] | |||
]); | |||
var options = { | |||
width: 450, height: 300, | |||
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"></div> | |||
</body> | |||
Revision as of 04:35, 5 February 2012