[Rd] Ellipsis to Two Functions When One Has Nested Functions

Dario Strbenac
Wed, 28 May 2014 06:00:16 -0000

Hello

If I have a function

aFunction <- function(data, alpha, ...)
{
    transform(alpha, ...)
    rowMeans(data) > alpha
}

f <- function(data, selection, ...)
{
    selected <- selection(data, ...)
    plot(data[selected, ], ...)
}

f(aDataset, aFunction, alpha = 10, pch = 19, transform = sqrt)

and selection calls another function, which has ... and that function calls
other functions, is there an easier way than getting the formals of all the
functions called internally by selection, and all of the formals of functions
called by plot ? Is there any option to change the error into a warning message
?

--------------------------------------
Dario Strbenac
PhD Student
University of Sydney
Camperdown NSW 2050
Australia