googleVis 0.3.0/0.3.1 is released: It’s faster!

[This article was first published on mages' blog, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here)
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

Version 0.3.0 of the googleVis package for R has been released on CRAN on 20 October 2012. With this version we have been able to speed up the code considerably. The transformation of R data frames into JSON works significantly faster. The execution of the gvisMotionChart function in the World Bank demo is over 35 times faster. Thanks to ideas by Wei Luo and in particular to Sebastian Kranz for providing the code.

Further, the plot function plot.gvis has gained a new argument 'browser'. This argument is passed on to the function browseURL. The 'browser' argument is by default set to the output of getOption("browser") in an interactive session, otherwise to 'false'. This prevents R CMD CHECK trying to open browser windows during the package checking process. Unfortunately this caused an error message under RStudio and RGui on Windows. The argument has been removed again and plot.gvis handles the check if R is running interactively internally. The bug has been fixed in googleVis-0.3.1, not yet available on CRAN, but on our project download page. Thanks to Henrik Bengtsson and Sebastian Kranz for their comments, suggestions and quick response.

Should you find any further issues or bugs with the new version, then please drop me a line or add them to our issues list.

Sebastian also suggested to add arguments to gvisMotionChart allowing the user to set the defaults for the various visible dimensions, namely: xvar, yvar, colorvar and sizevar. Here is a simple example using the new optional arguments:

Screen shot of a motion chart

The defaults of those new arguments are set to “”, which means gvisMotionChart will assume the columns in order of your data frame. This is the same behaviour as in the previous versions of googleVis.

Thanks to feedback from Erik Bülow the mechanism to load the Google API is now handeled via a secure https-connection rather than http.

Finally, we included a new example in the help file of gvisMap, demonstrating how to include html code into tooltips:

To leave a comment for the author, please follow the link and comment on their blog: mages' blog. offers daily e-mail updates about R news and tutorials about learning R and many other topics. Click here if you're looking to post or find an R/data-science job.
Want to share your content on R-bloggers? click here if you have a blog, or here if you don't.

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)