[Bioc-devel] BiocParallel Variable Not Found

Martin Morgan mtmorg@n@b|oc @end|ng |rom gm@||@com
Tue Mar 17 21:07:12 CET 2020


The question is a bit abstract for me to understand and it might be better to point to actual code in a git repository or similar... 

Inside a package, something like

fun = function(x, y, ...) {
    c(x, y, length(as.list(...)))
}

user_visible <- function(x, ...) {
    y = 1
    internal_function(x, y, ...)
}

internal_function <- function(x, y, ...) {
    bplapply(1:5, fun, x, y, ...)
}

I think would 'work'.

Martin

On 3/17/20, 4:00 PM, "Bioc-devel on behalf of Dario Strbenac" <bioc-devel-bounces using r-project.org on behalf of dstr7320 using uni.sydney.edu.au> wrote:

    Good day,
    
    Thanks for the examples which demonstrate the issue. Do you have other recommendations if, inside the loop, another function in the package is being called and the variable being passed is the ellipsis? There are only a couple of variables which might be provided by the user collected in the ellipsis, so the functional approach might still be the best in that case.
    
    --------------------------------------
    Dario Strbenac
    University of Sydney
    Camperdown NSW 2050
    Australia
    _______________________________________________
    Bioc-devel using r-project.org mailing list
    https://stat.ethz.ch/mailman/listinfo/bioc-devel
    


More information about the Bioc-devel mailing list