You appear to have a chain of google.setOnLoadCallback, which is an odd
style, but shouldn't be affecting your performance. I'd still recommend
that you change the style, though, since it'll be easier for you to make
other improvements once you do. Generally, you should have just one
callback function that draws all the charts.

>From there, we can improve the perceived performance. Each individual chart
doesn't take very long to render, but the durations will add up. If you do
a each draw in a setTimeout, that will let the browser handle interactivity
between each chart draw and schedule each function on its own time. So at
least, the page will load and not remain blank. I attached a formatted
version of your HTML that does this.

Another technique you might want to try is not rendering the chart until
the div is actually visible on the page. I think this is the same technique
as infinite scrolling, but I've never implemented this myself. Here's a
link to a stackoverflow question that seems relevant:
http://stackoverflow.com/questions/8192651/load-lazy-loading-a-div-whenever-the-div-gets-visible-for-the-first-time

Hopefully this helps.

On Wed Dec 03 2014 at 1:23:27 PM Nigel Griffiths <[email protected]>
wrote:

> Wow thanks for the advice.
> Pretty sure I only load the chart library once.
>
> The attached is a complete small example with just 30 data points per
> graph (14 of them) - which displays in 3 seconds but typically I have 300+
> data points per graph which takes just 14 seconds but feels s o    l o  n
> g.
> The data is embedded in the webpage to KISS - as these are generated.
> I think my problem is purely size, I have 14 x 300 = 4200 data point - so
> I am asking for a lot processing.
> Hence getting the first chart to display and then continuing to generate
> the other charts would make the page look responsive.
> Phase two would be getting the data from a web database.
>
> I will look into the OnClick option.
>
> Thanks again, Nigel
>
> --
> 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.

File: sampleC.nmon


  • nmon data graphed by nmon_charter (v3) using Google Charts. Author @mr_nmon

  • Host:sampleC
  • Online Virtual CPUs : 7
  • Date:01-DEC-2014
  • Entitled Capacity : 7.00
  • Time:00:00:06
  • Mode : Uncapped
  • Interval:1200
  • Online Memory : 63488 MB
  • Snapshots: 31
  • Type : Shared-SMT-4















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

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