Rendering Graphs in the browsers

38 views
Skip to first unread message

Miki

unread,
Mar 18, 2011, 1:24:17 PM3/18/11
to clj...@googlegroups.com
Greetings,

Last night Avram commented that he now prefers to visualize graphs in the browser (vs Incanter, SciPy, R ...).

My warning that this works well until you have big amounts of data. When data (number of points in the graphs)
starts to be big (more than 1000 in my experience) all the in-browser graphing packages I've found so far start to
hog CPU and hang the browser.

You can either "bin" your data on the server, or render graphs server side. There I found good old gnuplot to be blazing fast
(though it's default settings produces pretty ugly graphs :).

Just my 2c,
--
Miki

Avram

unread,
Mar 18, 2011, 2:20:09 PM3/18/11
to clj-la
Miki, your warning is spot on.

I try to stay in the "sweet zone" of each data tool used and ask
myself if a graph really requires all data points in order to be
informative. There are times when an aggregation of values will
suffice. For example, if the window of time is one year, it may be
overkill to plot hourly data. I might bring the hourly level time
series data for a 365-day span down to a daily level of data
aggregation, or perhaps compute boxplots for a weekly or monthly data
level, to give a sense of the distribution. Sometimes presenting less
can yield less noise, more signal, and a clearer message.

Also, as you suggest, creating "bins" of data works as well. Gnuplot
is great, though I tend to favor ggplot2 when I'm already working in
R.
I'm relatively new to javascript, but my preferences are definitely
leaning towards browser-based visualizations. See the okcupid blog for
an example of its flexibility/expressivity: http://blog.okcupid.com/

I wonder if clojurescript ( https://github.com/richhickey/clojure-contrib/tree/master/clojurescript/
) will eventually be a way to achieve some of the innovation occurring
in javascript currently (html5/canvas, jquery, flot, jstat,
processingjs, etc… ?

Cheers,
-Avram

Avram

unread,
Mar 18, 2011, 2:25:26 PM3/18/11
to clj-la

oops, looks like the okcupid blog relies mostly on png images with
just a dabble of interactivity.

Perhaps http://www.jstat.org/ is a better example…?

~A

Miki Tebeka

unread,
Mar 18, 2011, 2:44:16 PM3/18/11
to clj...@googlegroups.com
I've used both http://code.google.com/p/flot/ and http://www.fusioncharts.com/free/ (I *think*).
Here at work we use YUI which has charting as well - http://developer.yahoo.com/yui/3/charts/

There are html5 chart packages popping all over the place, can't recommend one though.

Avram

unread,
Mar 18, 2011, 2:47:30 PM3/18/11
to clj-la

I've used flot and dygraphs (http://dygraphs.com/). Both are great.

Right now I really like protovis out of stanford: http://vis.stanford.edu/protovis/ex/


On Mar 18, 11:44 am, Miki Tebeka <miki.teb...@gmail.com> wrote:
> I've used bothhttp://code.google.com/p/flot/andhttp://www.fusioncharts.com/free/(I *think*).
> Here at work we use YUI which has charting as well -http://developer.yahoo.com/yui/3/charts/
Reply all
Reply to author
Forward
0 new messages