[R] something missing in summary()

Jari Oksanen jarioksa at sun3.oulu.fi
Fri Feb 16 13:53:35 CET 2007


Gerard Smits g_smits at verizon.net Fri Feb 16 00:46:09 CET 2007:
> just noticed that two key pieces of information are not given by 
> the summary() command:  N and SD.  we are given the N missing, but 
> not the converse.  I know these summary value can be obtained easy, 
> but can't understand why these two pieces of information are not 
> provided with the other info.
> 
I assume you mean summary.data.frame?

There has even been an "appeal" on this:
http://tolstoy.newcastle.edu.au/R/help/06/02/20706.html

However, I didn't find any petition you could sign (but I found many
surprising petitions when googling on this). Perhaps somebody will set
up a petition page some day.

With time, I've learnt that if something obvious is missing in the base
R, there is a reason. Probably the Core thinks that you shouldn't use sd
in a summary, but it is a poor and misleading statistic (they neither
have skewness and kurtosis). You may learn to live without sd if you
survive over the first impact. 

On the other hand, there are things like R-squared and significance
stars in summary.lm, which spoils the image of purity in the Core. 

Number of observations may not be very useful in summary.data.frame,
because it varies so little among variables.

The R-help message cited above and its follow-ups suggest some ways of
locally modifying the code and maintaining the modifications over the
upgrades of R. 

Best wishes, Jari Oksanen



More information about the R-help mailing list