CRAN Package Check Results for Package mvbutils

Last updated on 2026-05-26 03:51:32 CEST.

Flavor Version Tinstall Tcheck Ttotal Status Flags
r-devel-linux-x86_64-debian-clang 2.8.232 3.59 94.54 98.13 NOTE
r-devel-linux-x86_64-debian-gcc 2.8.232 2.94 62.10 65.04 NOTE
r-devel-linux-x86_64-fedora-clang 2.8.232 7.00 162.32 169.32 OK
r-devel-linux-x86_64-fedora-gcc 2.12.120 8.00 205.64 213.64 OK
r-devel-windows-x86_64 2.8.232 5.00 115.00 120.00 OK
r-patched-linux-x86_64 2.8.232 6.27 90.70 96.97 OK
r-release-linux-x86_64 2.8.232 3.80 90.95 94.75 OK
r-release-macos-arm64 2.12.120 1.00 63.00 64.00 ERROR
r-release-macos-x86_64 2.12.120 3.00 188.00 191.00 ERROR
r-release-windows-x86_64 2.8.232 6.00 112.00 118.00 OK
r-oldrel-macos-arm64 2.12.120 ERROR
r-oldrel-macos-x86_64 2.12.120 3.00 179.00 182.00 ERROR
r-oldrel-windows-x86_64 2.8.232 6.00 104.00 110.00 OK

Check Details

Version: 2.8.232
Check: CRAN incoming feasibility
Result: NOTE Maintainer: ‘Mark V. Bravington <mark.bravington@csiro.au>’ No Authors@R field in DESCRIPTION. Please add one, modifying Authors@R: person(given = c("Mark", "V."), family = "Bravington", role = c("aut", "cre"), email = "mark.bravington@csiro.au") as necessary. Flavors: r-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc

Version: 2.12.120
Check: examples
Result: ERROR Running examples in ‘mvbutils-Ex.R’ failed The error most likely occurred in: > ### Name: numvbderiv_parallel > ### Title: Economy numerical derivatives > ### Aliases: numvbderiv_parallel numvbderiv > ### Keywords: misc > > ### ** Examples > > # Complex numbers are OK: > numvbderiv( function( x) x*x, complex( real=1, imaginary=3)) [1] 2+6i > # [1] 2+6i > # Parallel example... the whole point is to show speed and generality > # Works fine on my machine > # But if testing under CRAN, which I normally never do, > # then CRAN's ludicrous 2-core limit, and deliberate inability to > # check CRANality (or even number of cores _allowed_) while running, > # makes this completely ridiculous > # Not for the first time > # I have used the function 'get_ncores_CRANal' to try to get round this... > if( require( 'doParallel')){ # auto loads foreach, iterators, parallel thx2 "Depends" + ncores <- detectCores( logical=FALSE) + scatn( '%i cores really found', ncores) + if( ncores > 2 ){ # pointless otherwise + # Need a slowish example. 1e5 is too small; 1e7 better, + # ... but hard on auto builders eg R-universe + BIGGOVAL <- 1e5 + slowfun <- function( pars, BIGGO) + sum( sqr( 1+1/outer( seq_len( BIGGO), pars))) + parstart <- rep( 2, 8) + system.time( + dscalar <- numvbderiv( slowfun, parstart, + BIGGO=BIGGOVAL # named extra param (part of ...) + ) + ) # scalar + # Make "doPar back end". I do not know what I am doing ... + # NB I like to leave some cores spare, hence "-1"-- + # superstition, really + ncores_target <- min( ncores-1, length( parstart)) + # Anti CRANky: ignore on your own machine: + # ncores_target should just work + ncores_avail <- get_ncores_CRANal( ncores_target) + scatn( 'Using %i cores eg cozza CRAN', ncores_avail) + CLUSTO <- makeCluster( ncores_avail) + registerDoParallel( CLUSTO, ncores_avail) + # Next bit ensures slaves can find packages... sigh. + # Necessary _here_ coz example, but you may not need it + # clusterCall does not work properly :/, so the "obvious" fails: + # clusterCall( CLUSTO, .libPaths, .libPaths()) + # Instead, we are forced into this nonsense: + print( # for debuggery with as-CRAN + eval( substitute( + clusterEvalQ( CLUSTO, .libPaths( lb)), + list( lb=.libPaths()))) + ) + # Need 'mvbutils::sqr', hence '.packages' arg + scatn( 'Starting parallel time test') + print( system.time( + dpara <- numvbderiv_parallel( slowfun, parstart, + BIGGO=BIGGOVAL, # named extra parameter + FOREACH_ARGS=list( .packages= 'mvbutils') + ) + ) + ) + scatn( 'Done') + print( rbind( dscalar, dpara)) + # To refer to other data (ie beside params) + # best practice is to put it into function's environment + # (generally true, not just for numvbderiv) + e <- new.env() + e$paroffset <- c( 6, -3) + fun2 <- function( pars) { # not a speed test, can be smaller + sum( sqr( 1+1/outer( 1:1e3, pars+paroffset))) + } + environment( fun2) <- e + scatn( 'Scalar, using extra data via environment') + print( numvbderiv( fun2, parstart)) + # Parallel version should still work, coz function's environment + # is also passed to slaves + scatn( 'Trying parallel version...') + print( try({ + numvbderiv_parallel( fun2, parstart, + FOREACH_ARGS=list( .packages= 'mvbutils') + ) + }) + ) + # Sometimes you do need to explicitly export stuff to the slave processes + # Here's a version that will get paroffset from datenv + # datenv must exist... + alt_fun2 <- function( pars){ + environment( fun2) <- list2env( datenv) + fun2( pars) + } + scatn( 'With explicit data (in parallel)') + datenv <- as.list( e) + print( numvbderiv_parallel( alt_fun2, parstart, + FOREACH_ARGS=list( + .packages= 'mvbutils', + .export= cq( datenv, fun2) # stuff that alt_fun2 refers to + ) + ) + ) + # Always tidy up your clusters once you have finished playing + stopImplicitCluster() + stopCluster( CLUSTO) + rm( CLUSTO) + } # if ncores>2 + } # parallel Loading required package: doParallel Loading required package: foreach Loading required package: iterators Loading required package: parallel 12 cores really found Error in stopCluster(CLUSTO) : CRANtidote Calls: get_ncores_CRANal -> stopCluster Execution halted Flavor: r-release-macos-arm64

Version: 2.12.120
Check: examples
Result: ERROR Running examples in ‘mvbutils-Ex.R’ failed The error most likely occurred in: > ### Name: numvbderiv_parallel > ### Title: Economy numerical derivatives > ### Aliases: numvbderiv_parallel numvbderiv > ### Keywords: misc > > ### ** Examples > > # Complex numbers are OK: > numvbderiv( function( x) x*x, complex( real=1, imaginary=3)) [1] 2+6i > # [1] 2+6i > # Parallel example... the whole point is to show speed and generality > # Works fine on my machine > # But if testing under CRAN, which I normally never do, > # then CRAN's ludicrous 2-core limit, and deliberate inability to > # check CRANality (or even number of cores _allowed_) while running, > # makes this completely ridiculous > # Not for the first time > # I have used the function 'get_ncores_CRANal' to try to get round this... > if( require( 'doParallel')){ # auto loads foreach, iterators, parallel thx2 "Depends" + ncores <- detectCores( logical=FALSE) + scatn( '%i cores really found', ncores) + if( ncores > 2 ){ # pointless otherwise + # Need a slowish example. 1e5 is too small; 1e7 better, + # ... but hard on auto builders eg R-universe + BIGGOVAL <- 1e5 + slowfun <- function( pars, BIGGO) + sum( sqr( 1+1/outer( seq_len( BIGGO), pars))) + parstart <- rep( 2, 8) + system.time( + dscalar <- numvbderiv( slowfun, parstart, + BIGGO=BIGGOVAL # named extra param (part of ...) + ) + ) # scalar + # Make "doPar back end". I do not know what I am doing ... + # NB I like to leave some cores spare, hence "-1"-- + # superstition, really + ncores_target <- min( ncores-1, length( parstart)) + # Anti CRANky: ignore on your own machine: + # ncores_target should just work + ncores_avail <- get_ncores_CRANal( ncores_target) + scatn( 'Using %i cores eg cozza CRAN', ncores_avail) + CLUSTO <- makeCluster( ncores_avail) + registerDoParallel( CLUSTO, ncores_avail) + # Next bit ensures slaves can find packages... sigh. + # Necessary _here_ coz example, but you may not need it + # clusterCall does not work properly :/, so the "obvious" fails: + # clusterCall( CLUSTO, .libPaths, .libPaths()) + # Instead, we are forced into this nonsense: + print( # for debuggery with as-CRAN + eval( substitute( + clusterEvalQ( CLUSTO, .libPaths( lb)), + list( lb=.libPaths()))) + ) + # Need 'mvbutils::sqr', hence '.packages' arg + scatn( 'Starting parallel time test') + print( system.time( + dpara <- numvbderiv_parallel( slowfun, parstart, + BIGGO=BIGGOVAL, # named extra parameter + FOREACH_ARGS=list( .packages= 'mvbutils') + ) + ) + ) + scatn( 'Done') + print( rbind( dscalar, dpara)) + # To refer to other data (ie beside params) + # best practice is to put it into function's environment + # (generally true, not just for numvbderiv) + e <- new.env() + e$paroffset <- c( 6, -3) + fun2 <- function( pars) { # not a speed test, can be smaller + sum( sqr( 1+1/outer( 1:1e3, pars+paroffset))) + } + environment( fun2) <- e + scatn( 'Scalar, using extra data via environment') + print( numvbderiv( fun2, parstart)) + # Parallel version should still work, coz function's environment + # is also passed to slaves + scatn( 'Trying parallel version...') + print( try({ + numvbderiv_parallel( fun2, parstart, + FOREACH_ARGS=list( .packages= 'mvbutils') + ) + }) + ) + # Sometimes you do need to explicitly export stuff to the slave processes + # Here's a version that will get paroffset from datenv + # datenv must exist... + alt_fun2 <- function( pars){ + environment( fun2) <- list2env( datenv) + fun2( pars) + } + scatn( 'With explicit data (in parallel)') + datenv <- as.list( e) + print( numvbderiv_parallel( alt_fun2, parstart, + FOREACH_ARGS=list( + .packages= 'mvbutils', + .export= cq( datenv, fun2) # stuff that alt_fun2 refers to + ) + ) + ) + # Always tidy up your clusters once you have finished playing + stopImplicitCluster() + stopCluster( CLUSTO) + rm( CLUSTO) + } # if ncores>2 + } # parallel Loading required package: doParallel Loading required package: foreach Loading required package: iterators Loading required package: parallel 6 cores really found Error in stopCluster(CLUSTO) : CRANtidote Calls: get_ncores_CRANal -> stopCluster Execution halted Flavors: r-release-macos-x86_64, r-oldrel-macos-x86_64

Version: 2.12.120
Check: R code for possible problems
Result: NOTE cd.load: possible error in mget("tasks", pos = 2, ifnotfound = list(character(0))): unused argument (pos = 2) get.cd.from.menu: possible error in mget("tasks", pos = 1, ifnotfound = list(structure(character(0), names = character(0)))): unused argument (pos = 1) make.new.cd.task: possible error in mget("tasks", pos = 2, ifnotfound = list(character(0))): unused argument (pos = 2) Flavors: r-oldrel-macos-arm64, r-oldrel-macos-x86_64

Version: 2.12.120
Check: examples
Result: ERROR Running examples in ‘mvbutils-Ex.R’ failed The error most likely occurred in: > ### Name: numvbderiv_parallel > ### Title: Economy numerical derivatives > ### Aliases: numvbderiv_parallel numvbderiv > ### Keywords: misc > > ### ** Examples > > # Complex numbers are OK: > numvbderiv( function( x) x*x, complex( real=1, imaginary=3)) [1] 2+6i > # [1] 2+6i > # Parallel example... the whole point is to show speed and generality > # Works fine on my machine > # But if testing under CRAN, which I normally never do, > # then CRAN's ludicrous 2-core limit, and deliberate inability to > # check CRANality (or even number of cores _allowed_) while running, > # makes this completely ridiculous > # Not for the first time > # I have used the function 'get_ncores_CRANal' to try to get round this... > if( require( 'doParallel')){ # auto loads foreach, iterators, parallel thx2 "Depends" + ncores <- detectCores( logical=FALSE) + scatn( '%i cores really found', ncores) + if( ncores > 2 ){ # pointless otherwise + # Need a slowish example. 1e5 is too small; 1e7 better, + # ... but hard on auto builders eg R-universe + BIGGOVAL <- 1e5 + slowfun <- function( pars, BIGGO) + sum( sqr( 1+1/outer( seq_len( BIGGO), pars))) + parstart <- rep( 2, 8) + system.time( + dscalar <- numvbderiv( slowfun, parstart, + BIGGO=BIGGOVAL # named extra param (part of ...) + ) + ) # scalar + # Make "doPar back end". I do not know what I am doing ... + # NB I like to leave some cores spare, hence "-1"-- + # superstition, really + ncores_target <- min( ncores-1, length( parstart)) + # Anti CRANky: ignore on your own machine: + # ncores_target should just work + ncores_avail <- get_ncores_CRANal( ncores_target) + scatn( 'Using %i cores eg cozza CRAN', ncores_avail) + CLUSTO <- makeCluster( ncores_avail) + registerDoParallel( CLUSTO, ncores_avail) + # Next bit ensures slaves can find packages... sigh. + # Necessary _here_ coz example, but you may not need it + # clusterCall does not work properly :/, so the "obvious" fails: + # clusterCall( CLUSTO, .libPaths, .libPaths()) + # Instead, we are forced into this nonsense: + print( # for debuggery with as-CRAN + eval( substitute( + clusterEvalQ( CLUSTO, .libPaths( lb)), + list( lb=.libPaths()))) + ) + # Need 'mvbutils::sqr', hence '.packages' arg + scatn( 'Starting parallel time test') + print( system.time( + dpara <- numvbderiv_parallel( slowfun, parstart, + BIGGO=BIGGOVAL, # named extra parameter + FOREACH_ARGS=list( .packages= 'mvbutils') + ) + ) + ) + scatn( 'Done') + print( rbind( dscalar, dpara)) + # To refer to other data (ie beside params) + # best practice is to put it into function's environment + # (generally true, not just for numvbderiv) + e <- new.env() + e$paroffset <- c( 6, -3) + fun2 <- function( pars) { # not a speed test, can be smaller + sum( sqr( 1+1/outer( 1:1e3, pars+paroffset))) + } + environment( fun2) <- e + scatn( 'Scalar, using extra data via environment') + print( numvbderiv( fun2, parstart)) + # Parallel version should still work, coz function's environment + # is also passed to slaves + scatn( 'Trying parallel version...') + print( try({ + numvbderiv_parallel( fun2, parstart, + FOREACH_ARGS=list( .packages= 'mvbutils') + ) + }) + ) + # Sometimes you do need to explicitly export stuff to the slave processes + # Here's a version that will get paroffset from datenv + # datenv must exist... + alt_fun2 <- function( pars){ + environment( fun2) <- list2env( datenv) + fun2( pars) + } + scatn( 'With explicit data (in parallel)') + datenv <- as.list( e) + print( numvbderiv_parallel( alt_fun2, parstart, + FOREACH_ARGS=list( + .packages= 'mvbutils', + .export= cq( datenv, fun2) # stuff that alt_fun2 refers to + ) + ) + ) + # Always tidy up your clusters once you have finished playing + stopImplicitCluster() + stopCluster( CLUSTO) + rm( CLUSTO) + } # if ncores>2 + } # parallel Loading required package: doParallel Loading required package: foreach Loading required package: iterators Loading required package: parallel 16 cores really found Error in stopCluster(CLUSTO) : CRANtidote Calls: get_ncores_CRANal -> stopCluster Execution halted Flavor: r-oldrel-macos-arm64