Created
February 6, 2012 08:40
-
-
Save andrewxhill/1750808 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function drawVisualization() { | |
// Create and populate the data table. | |
var data = new google.visualization.DataTable(); | |
data.addColumn('string', 'country'); | |
data.addColumn('number', '2005'); | |
data.addColumn('number', '2010'); | |
data.addRow(["Andorra", 34.04255319, 34.04255319]); | |
data.addRow(["Belarus", 41.59148055, 42.55004437]); | |
data.addRow(["Comoros", 2.688172043, 1.612903226]); | |
data.addRow(["Gabon", 85.38052548, 85.38052548]); | |
data.addRow(["Italy", 29.77833685, 31.10423608]); | |
// Create and draw the visualization. | |
new google.visualization.LineChart(document.getElementById('visualization')). | |
draw(data, {curveType: "function", | |
width: 500, height: 400, | |
vAxis: {maxValue: 100}} | |
); | |
} | |
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment