[Rd] sum and partial argument name matching

From: Patrick Burns <pburns_at_pburns.seanet.com>
Date: Sun 21 Nov 2004 - 07:55:49 EST


"sum" (and perhaps other functions?) allows partial argument name matching after its three-dots argument:

> sum(1:4, NA, n=78, na.rm=FALSE)

[1] 10
> sum(1:4, NA, n=78, na.rm=TRUE)

[1] 11

I can see there could be a discussion about whether or not this is a bug, but I think all will agree that it's a might peculiar.

This is done in 2.0.1 but the same behavior is in 1.8.1.

> version

         _
platform i386-pc-mingw32

arch     i386          
os       mingw32       
system   i386, mingw32 
status                 
major    2             
minor    0.1           
year     2004          
month    11            
day      15            

language R

Patrick Burns

Burns Statistics
patrick@burns-stat.com
+44 (0)20 8525 0696
http://www.burns-stat.com
(home of S Poetry and "A Guide for the Unwilling S User")



R-devel@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Sun Nov 21 08:02:30 2004

This archive was generated by hypermail 2.1.8 : Fri 18 Mar 2005 - 09:01:38 EST