# #——回声= FALSE,包括= FALSE -------------------------------------------- knitr: opts_chunk美元集(整洁= FALSE,缓存= TRUE, dev =“png”,消息= FALSE,错误= FALSE,警告= TRUE ) ## ----------------------------------------------------------------------------- 库(SummarizedBenchmark)库(magrittr ) ## ----------------------------------------------------------------------------- bdslow < - BenchDesign (data = tdat) % > %调用addMethod(“slowMethod函数(){Sys.sleep (5);rnorm(5)}, post = list(keepSlow = identity, makeSlower = function(x) {Sys.sleep(5);x})) %>% addMethod("fastMethod", function() {rnorm(5)}, post = list(keepFast = identity, makeSlower = function(x) {Sys.sleep(5);x })) ## ---- 消息= TRUE ---------------------------------------------------------- bpp < - SerialParam () bptimeout (bpp) < - 1 sbep < - buildBench (bdslow、并行= TRUE BPPARAM = bpp ) ## ----------------------------------------------------------------------------- sbep ## ----------------------------------------------------------------------------- 酸式焦磷酸钠(assayNames (sbep)、试验、x = sbep,简化= FALSE ) ## ----------------------------------------------------------------------------- 名称(元数据(sbep)会议[[1美元 ]]) ## ----------------------------------------------------------------------------- sess1res < -元数据(sbep)会议[[1]]结果simplify2array美元(sess1res ) ## ----------------------------------------------------------------------------- sess1res slowMethod keepSlow美元