Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/r/71.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
是否可以增大R条形图中边界框的大小?_R - Fatal编程技术网

是否可以增大R条形图中边界框的大小?

是否可以增大R条形图中边界框的大小?,r,R,考虑以下条形图代码 pdf("ThreadCreationLatency.pdf") B <- c(52.6,26.2,0.6) pp <- barplot(B, main="Thread Creation to First Instruction", ylab="Time (us)", names.arg=c("std::thread", "Goroutines", "Arachne"), cex.names=1.5, cex.axis=1.5,

考虑以下
条形图
代码

pdf("ThreadCreationLatency.pdf")
B <- c(52.6,26.2,0.6)
pp <- barplot(B, main="Thread Creation to First Instruction", ylab="Time (us)", 
        names.arg=c("std::thread", "Goroutines", "Arachne"),
        cex.names=1.5, cex.axis=1.5, cex.lab=1.5, cex.main=1.5, ylim=c(0,60))
text(x=pp , y=B+2, labels=as.character(B), xpd=TRUE, cex=1.5)

dev.off()
pdf(“ThreadCreationLatency.pdf”)
B(这是基本绘图世界,因此请务必研究
?par
帮助页面。)记住
par('mar')的默认值(或知道如何恢复它们)是很有帮助的:

因此,在左侧边距上加1,这是这些数字中的第二个:

pdf("ThreadCreationLatency.pdf")
B <- c(52.6,26.2,0.6); par(mar=par('mar')+c(0, 1,0,0) )
pp <- barplot(B, main="Thread Creation to First Instruction", ylab="Time (us)", 
        names.arg=c("std::thread", "Goroutines", "Arachne"),
        cex.names=1.5, cex.axis=1.5, cex.lab=1.5, cex.main=1.5, ylim=c(0,60))
text(x=pp , y=B+2, labels=as.character(B), xpd=TRUE, cex=1.6)

dev.off()
pdf(“ThreadCreationLatency.pdf”)

B参见
?par
-具体地说是
par(mar=…)
,为了调整每一面的边距,请仔细阅读本页,我发现自己经常引用它:
pdf("ThreadCreationLatency.pdf")
B <- c(52.6,26.2,0.6); par(mar=par('mar')+c(0, 1,0,0) )
pp <- barplot(B, main="Thread Creation to First Instruction", ylab="Time (us)", 
        names.arg=c("std::thread", "Goroutines", "Arachne"),
        cex.names=1.5, cex.axis=1.5, cex.lab=1.5, cex.main=1.5, ylim=c(0,60))
text(x=pp , y=B+2, labels=as.character(B), xpd=TRUE, cex=1.6)

dev.off()