Hi Nigel,

I'd love to help you get your page working faster, but it's a little
difficult to diagnose your issues without being able to play with and
profile the page. However, a common mistake that people make is having
multiple google.load calls, generally people either have one per package or
one per chart. You should *not* do this.

You should have one google.load call that loads all the packages that your
page will need.

Another thing that might be slowing you down is your data fetching. If you
have 15 charts, and each one of them fires an AJAX request, that won't
really end well. You should group and bundle your data as much as you can
and then filter it on the client. Alternatively, your server can just
return all 15 DataTables simultaneously, instead of having a separate
request for each.

*Getting your charts working with OnClick*
Some users find this to be a bit tricky. Since you didn't outline exactly
how you failed to get this working, I'll just speak about the most common
issue: the div should be visible when the chart is drawing. We use the div
for text measurement, so all kinds of things might be off if your div isn't
visible, since text sizes won't be reported properly. This generally only
applies to display: none, and not to visible: false, although that might
not be entirely true. But you shouldn't even have to use display or
visible, if you're rendering the charts into the same div. Here's an
example of buttons drawing charts: http://jsfiddle.net/yfLng7y1/

I hope this helps! Please post back with more information if you have any
further questions.

On Tue Dec 02 2014 at 5:27:15 PM Nigel Griffiths <[email protected]>
wrote:

> HI,
> I want to display at least 15 related graphs on one web page.
> - these are UNIX performance stats for on VM for a day based on nmon data.
> - 1 to 4 stats with 100 to 700 data points per graph
> But I find the whole pages is blank until all the graphs are generated
> which takes 12 seconds to load = which too long.
>
> Is there a way to force the first graph to display ASAP - this gives the
> user eye candy, while the rest of the graphs are generated.
>
> Alternative a way to use OnClick on a button to get one of the graphs
> drawn at a time each in the same screen area.
> - I tried but failed to get that working using .visable and .display.
>
> Any hints/tips would be good, Cheers Nigel Griffiths.
>
> --
> 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 google-visualization-api@
> googlegroups.com.
> Visit this group at http://groups.google.com/
> group/google-visualization-api.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.

Reply via email to