Is there a limit of 4 series in a graph? I can't get more than 4 to work in a bar, queued_bar or line graph.

Comments

hshana’s picture

Sorry, should have mentioned I was using google charts.

hshana’s picture

I did some more testing and I got a graph with more than 4 series, but I still couldn't get my original graph with 7 to work. So I continued to test it and I think it has to do with the layout of the legends. For some reason if I shortened the title, it works with 7 series like this:

$canvas4->title = "Monthly Average Power test test";

$canvas4->series = array(
'Bonneville-USBR' => $series1,
'Bonneville-USCE' => $series2,
'Southeastern-USCE' => $series3,
'Southwestern-USCE' => $series4,
'Southeastern-TVA' => $series5,
'Western-USCE' => $series6,
'Western-USBR' => $series7,
);

but
$canvas4->title = "Monthly Average Power test test test";

pushes the chart legend to the right of the graph from underneath the graph and

$canvas4->title = "Monthly Average Power test test test test";

no graph is shown unless I take out two series.

What's even stranger is right below this I have a second graph with a title just as long as the last example and with 7 series and the same legend and layout parameters and everything works fine. The only difference that I can tell is that there are 39 data points in each series in the first graph and only 12 in the second.

I assume there is some interplay behind the scenes messing with things. Hopefully documenting helps the next guy about to pull out all of his hair.

hshana’s picture

So I ran into the same problem again trying to graph serveral series with about 100 data points each. There appears to be a limit on the amount of data (length of the url) you can pass back and forth so the process breaks (http://groups.google.com/group/google-chart-api/browse_thread/thread/d30...). This also looks to be due to microsoft (http://support.microsoft.com/kb/208427). Thanks again microsoft. Does the module support the encoding that is mentioned here (http://code.google.com/apis/chart/docs/data_formats.html#extended). Should be possible by just overriding the parameter, right?

rsevero’s picture

Assigned: Unassigned » rsevero
Status: Active » Fixed

Google Charts imposes a limit of 2K URLs for charts generated with GET HTTP method as you already found out.

You can always override any parameter but there will still be a 2K limit with GET.

Patches to include support for POST HTTP method are welcomed.

Included mention of this limit on Google Charts help page with http://drupal.org/cvs?commit=443830.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.