[R] Why na.rm=FALSE is the default

Adam D. I. Kramer adik at uoregon.edu
Tue Mar 24 19:23:33 CET 2009


Dear Colleagues,

 	I've been searching for a post or article or something which
explains why having na.rm=FALSE or na.action=na.fail as the default is a
better choice than TRUE or na.omit.

 	I understand the basic argument: it does not make sense to average a
nonexistance into an aggregate, and removing them implicitly leads to
accidental pairwise deletion in some cases, and sum(x) / length(x) < mean(x)
(which many would find disturbing)...I'm just looking for a source to cite
on this issue to support mimicking R's behavior in a database system's
aggregating functions (sum, avg, var, etc.).

Cordially,
Adam Kramer
Ph.D. Candidate, Social Psychology
University of Oregon
adik at uoregon dot edu




More information about the R-help mailing list