Skip to content

Instantly share code, notes, and snippets.

@terrancesnyder
Created April 4, 2013 01:40
Show Gist options
  • Save terrancesnyder/5307015 to your computer and use it in GitHub Desktop.
Save terrancesnyder/5307015 to your computer and use it in GitHub Desktop.
Google Charts for C/I
function drawVisualization() {
// Create and populate the data table.
// sum total distinct rows and then take each group % of share of total distinct
var data = google.visualization.arrayToDataTable([
['Year', 'Group A', 'Group B', 'Group C', 'Group D'],
['Group A', 100, 100, 100, 100],
['Group B', 100, 100, 100, 100],
]);
// Create and draw the visualization.
new google.visualization.BarChart(document.getElementById('visualization')).
draw(data,
{title:"Compare/Intersect",
width:600, height:400,
vAxis: {title: "Groups"},
hAxis: {title: "# Rows"},
isStacked: true}
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment