Description Usage Arguments Value See Also Examples
When ellipsis arguments so called ...
is given by user call,
frequently we want to overwrite some arguments as fixed desirable arguments.
This function helps to settles the situation simply.
1 | overwriteEllipsis(..., append = NULL, warn = T)
|
... |
fixed and given arguments. |
append |
argments list to be appended. |
warn |
if |
overwrited ellipsis.
1 2 3 4 5 6 7 8 9 10 | # plot function with xlim = c(0, 2 * pi) and col = 'red'
plot2pired <- function(x, ...){
elp <- overwriteEllipsis(..., x = x, xlim = c(0, 2 * pi), col = 'red')
do.call(plot, elp)
}
plot2pired(sin)
# this example is warned due to conflict argments
plot2pired(sin, main = 'sin curve', xlim = c(-pi, pi))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.