Skip to content

Instantly share code, notes, and snippets.

@griggheo
Created July 15, 2010 20:44
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save griggheo/477508 to your computer and use it in GitHub Desktop.
TEMPL = """
<html>
<head>
<script type="text/javascript" src="http://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(%(json)s,0.6);
var chart = new google.visualization.AreaChart(document.getElementById('chart_div'));
chart.draw(data, {width: 1200, height: 700, title: '%(title)s',
hAxis: {title: '5-Minute Intervals', titleColor:'#FF0000'}
});
}
</script>
</head>
<body>
<div id="chart_div"></div>
</body>
</html>
"""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment