nDotArgs | R Documentation |
count the number of ... arguments passed.
nDotArgs(...)
... |
... arguments or real arguments in the call to the function which calls |
the number of ... arguments in the call to the
function which calls nDotArgs
.
nargs
.
myfun <- function(..., a=4) nDotArgs(...)
myfun() ## returns 0
myfun(1:3,"bear") ## returns 2
myfun(a=5, 1:3, "bear") ## returns 2 (excludes a)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.