[R] check if a certain ... argument has been passed on to my user-defined function

Charles C. Berry cberry at tajo.ucsd.edu
Thu Dec 11 20:10:06 CET 2008



See

 	?match.call

and note the expand.dots arg.

HTH,

Chuck


On Thu, 11 Dec 2008, Mark Heckmann wrote:

> Hi,
>
> How can I check if a certain ... argument has been passed on to my
> user-defined function or not?
>
> foo <- function(data, ...)
> {
> ### here I want to check whether xlab was passed with the ... arguments
> ### or if the ... arguments did not contain an xlab argument
> }
>
> I tried  missing(xlab)  , exists(xlab) and several other things but did not
> find a solution.
>
> TIA,
> Mark
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>

Charles C. Berry                            (858) 534-2098
                                             Dept of Family/Preventive Medicine
E mailto:cberry at tajo.ucsd.edu	            UC San Diego
http://famprevmed.ucsd.edu/faculty/cberry/  La Jolla, San Diego 92093-0901



More information about the R-help mailing list