addDots: Extend a function's signature to include '...'

Description Usage Arguments Value Examples

View source: R/addDots.R

Description

modifies the input function to accept extra arguments, if it doesn't already.

Usage

1
addDots(func, .verbose = FALSE)

Arguments

func

the function whose signature is to be modified.

.verbose

logical flag indicating whether warnings should be displayed or not.

Value

a function with the same body as func but whose signature now includes ....

Examples

1
2
3
4
5
6
7
8
9
## Not run: 
f <- function(x,y) x^2 + y^2

g <- addDots(f)
g

h <- addDots(g, .verbose=TRUE)

## End(Not run)

boostr documentation built on May 2, 2019, 1:42 p.m.