“microbenchmark”中的“cld”列是什么意思?

问题描述 投票:0回答:2

一直以为

cld
输出中的
microbenchmark
那一栏是速度的统计排名。然而这不是真的:

> microbenchmark(
+   intmap = fintmap(), # slower
+   List   = flist(),
+   times = 5
+ )
Unit: microseconds
   expr     min      lq      mean  median       uq      max neval cld
 intmap 793.984 910.539 1145.8608 911.840 1290.529 1822.412     5  a 
   List   1.092   1.318  201.3712   1.639    3.660  999.147     5   b

那是什么?文档只说这是一个统计排名,但什么?

也许是速度的多重比较测试,但标准偏差的不平等会导致这样的问题?第二个基准显然有异常值。

r statistics microbenchmark
2个回答
0
投票

Compact Letter Display - 来自 multcomp 包,参见 multcomp::cld

GitHub microbenchmark print.R Line 15

#' @note If the \code{multcomp} package is available a statistical
#' ranking is calculated and displayed in compact letter display from
#' in the \code{cld} column.

0
投票

cld
是从包装中带来的紧凑型字母显示
multcomp
.

来自那个包裹:“相同的字母表示没有显着差异。”

我目前无法确定它是要排名还是只是分类,即

a
意味着通常比
b
快还是只是不同?

microbenchmark::summary
中的代码是:

      ops <- options(warn=-1)
      mdl <- lm(time ~ expr, object)
      comp <- multcomp::glht(mdl, multcomp::mcp(expr = "Tukey"))
      res$cld <- multcomp::cld(comp)$mcletters$monospacedLetters

因此,它似乎是从原始时间(而不是均值等)生成线性模型

lm()
,然后设置多个比较对象
glht()
进行所有对比较,然后使用
将其减少到cld cld()
.

© www.soinside.com 2019 - 2024. All rights reserved.