Skip to content
Prev 14194 / 398506 Next

Trouble with 3-dots

David Brahm  <a215020 at agate.fmr.com> writes:
If you use match.call rather than sys.call you get a construction type
that is used a couple of places in the R sources. Not dearly beloved
by its authors, but used nevertheless. (See lm, for instance)

Generally, combining missing and ... is asking for trouble and any
solution is going to be ugly in some way. 

There might be a cleaner way involving looking at 

match.call(expand.dots=FALSE)$...

but I don't quite see it. Be careful, there are lots of little
surprises in this stuff.

Time might be better spent figuring out why
Error: SubAssignArgs: invalid number of arguments

whereas x[]<-0 works fine. (So does "[<-"(x,,value=0), which could be
part of the explanation).