Monthly Archives: January 2011

Really useful bits of code that are missing from R

January 10, 2011
By
Really useful bits of code that are missing from R

There are some pieces of code that are so simple and obvious that they really ought to be included in base R somewhere. Geometric mean and standard deviation – a staple for anyone who deals with lognormally distributed data. geomean <- function(x, na.rm = FALSE, trim = 0, ...) { exp(mean(log(x, ...), na.rm = na.rm,

Read more »

R interface to Google Chart Tools

January 10, 2011
By

Hans Rosling eat your heart out! It is now possible to interface R statistics software to Google’s Gapminder inspired Chart Tools. The plots below were produced using the googleVis R package and three datasets from the Gapminder website. The first shows the relationship between income, life expectancy and population for 20 countries with the highest ...

Read more »

EmEditor R code macro – Almost interactive R development for Emeditor

January 10, 2011
By

Get the new macro now hosted on githubEdit 18th Jan 2011: The below text refers to the old version of the macro and is no longer relevant, a new post will  describe the new macro, and it is also documented on the github site.As a follow ...

Read more »

Using R for Introductory Statistics, Chapter 4, Model Formulae

January 10, 2011
By
Using R for Introductory Statistics, Chapter 4, Model Formulae

Several R functions take model formulae as parameters. Model formulae are symbolic expressions. They define a relationship between variables rather than an arithmetic expression to be evaluated immediately. Model formulae are defined with the tilde ope...

Read more »

Using R for Introductory Statistics, Chapter 4, Model Formulae

January 10, 2011
By
Using R for Introductory Statistics, Chapter 4, Model Formulae

Several R functions take model formulae as parameters. Model formulae are symbolic expressions. They define a relationship between variables rather than an arithmetic expression to be evaluated immediately. Model formulae are defined with the tilde ope...

Read more »

Batting and Bowling performance in Ashes 2010 – 2011

January 9, 2011
By
Batting and Bowling performance in Ashes 2010 – 2011

English cricket is strong once again. And it is great to see that (after all they invented the gentleman's game).In a sharp contrast to previous tours of Australia, England outplayed Australia on their home ground in the recently concluded Ashes 2...

Read more »

Batting and Bowling performance in Ashes 2010 – 2011

January 9, 2011
By
Batting and Bowling performance in Ashes 2010 – 2011

English cricket is strong once again. And it is great to see that (after all they invented the gentleman's game).In a sharp contrast to previous tours of Australia, England outplayed Australia on their home ground in the recently concluded Ashes 2...

Read more »

LearnR Toolkit To Help Excel Users Move Up To R

January 9, 2011
By
LearnR Toolkit To Help Excel Users Move Up To R

As a former  Excel chart user, I want to help current Excel users make the transition to more advanced charting R with as little difficulty as possible. This post introduces my LearnR Toolkit to help Excel users move up to … Continue reading ...

Read more »

From one extreme (0) to another (1): challenge failed, but who cares…

January 9, 2011
By
From one extreme (0) to another (1): challenge failed, but who cares…

Just after arriving in Montréal, at the beginning of September, I discussed statistics of my blog, and said that it might be possible - or likely - that by new year's Eve, over a million page would have been viewed on my blog (from Google's count...

Read more »

R and Google Visualization API

January 8, 2011
By
R and Google Visualization API

R interfaces with the powerful Google Visualization API with the package googleVis (see here). It's relatively easy to convert your graphics in R to interactive graphics to post on a web browser. And the graphics are quite nice, as seen below in a simple graph of some of my data collected from this summer on seed predation to...

Read more »