Please provide some code, because the following snippet thrown into
Code Playground definitely shows color assignments based upon the Data
Table row, not any sort of value:
function drawVisualization() {
// Create and populate the data table.
var data = new google.visualization.DataTable();
data.addColumn('string', 'Task');
data.addColumn('number', 'Hours per Day');
data.addRows(3);
data.setValue(0, 0, 'Should be Red');
data.setValue(0, 1, 10);
data.setValue(1, 0, 'Should be Orange');
data.setValue(1, 1, 20);
data.setValue(2, 0, 'Should be Green');
data.setValue(2, 1, 15);
// Create and draw the visualization.
new
google.visualization.PieChart(document.getElementById('visualization')).
draw(data, {title:"So, how was your day?",colors:
['red','orange','green']});
}
--
You received this message because you are subscribed to the Google Groups
"Google Visualization API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-visualization-api?hl=en.