一些想法:
- 为 y 轴标签使用较小的字体,例如
scale=list(y=list(cex=.6))。另一种方法是保持统一的字体大小,但将输出分隔在几个页面上(这可以通过layout= 进行控制),或者可能更好地显示来自同一数据集的所有数据(A 到 F,因此 4 分每个算法)或通过带有group= 选项的样本大小(10 到 100,因此每个算法为 6 分)。我个人会为此创建两个因素,sample.size 和 dataset.type。
-
重新调整因子Dataset,以便您感兴趣的数据集出现在layout 将放置它们的位置,或者(更好!)使用index.cond 为您的24 个面板指定特定排列。例如,
dfrm <- data.frame(algo=gl(11, 1, 11*24, labels=paste("algo", 1:11, sep="")),
type=gl(24, 11, 11*24, labels=paste("type", 1:24, sep="")),
roc=runif(11*24))
p <- dotplot(algo ~ roc | type, dfrm, layout=c(4,6), scale=list(y=list(cex=.4)))
将按顺序排列面板,从左下角到右上角(type1 在左下角,type24 在右上角),而
update(p, index.cond=list(24:1))
将以相反的顺序排列面板。只需指定带有预期面板位置的list。
这是我对第 1 点的想法以及使用两个因素而不是一个因素的示例。让我们生成另一个人工数据集:
dfrm <- data.frame(algo=gl(11, 1, 11*24, labels=paste("algo", 1:11, sep="")),
dataset=gl(6, 11, 11*24, labels=LETTERS[1:6]),
ssize=gl(4, 11*6, 11*24, labels=c(10,25,50,100)),
roc=runif(11*24))
xtabs(~ dataset + ssize, dfrm) # to check allocation of factor levels
dotplot(algo ~ roc | dataset, data=dfrm, group=ssize, type="l",
auto.key=list(space="top", column=4, cex=.8, title="Sample size",
cex.title=1, lines=TRUE, points=FALSE))