Thank you for your reply.
Apology for not making query clearer. I am trying to create a multi-series
line chart, which is triggered by selecting one or more names, from the
category filter control. The line chart should, create a multi-series,
when one or more 'name' column is selected from the category filter
control.
I was originally using the above example, to design this functionality. So
far, I am able to select multiple name's values, from the category filter
control, from the function below, *however its failing to create line chart
for the selected 'name' values from the category filter control.*
Is function still plausible? if so, how can I setup my function below
further, so it can, render multi-line graph, from the select multiple
name's values (category filter control).
google.visualization.events.addListener(control, 'statechange',
function () {
var filteredData = control.getState();
// get a list of all the labels in column 0
var group = filteredData.getDistinctValues(0);
for (var i = 0; i < state.selectedValues.length; i++) {
row = columnsTable.getFilteredRows([{ column: 1, value:
state.selectedValues[i] }])[0];
view.columns.push(columnsTable.getValue(row, 0));
}
var view = new google.visualization.DataView(filteredData);
view.setColumns(columns);
var groupedData = google.visualization.data.group(view,
[0], groupColumns);
line.setView({ columns: viewColumns });
line.setDataTable(groupedData);
line.draw();
});
The rest of code and can be found here (for further reference):
http://jsfiddle.net/miss/2c1djqu9/3/
Any advice/hint would be much appreciated. Many thanks.
--
You received this message because you are subscribed to the Google Groups
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-visualization-api.
For more options, visit https://groups.google.com/d/optout.