Change width of bars in barchart (R)

夙愿已清 提交于 2019-12-05 06:53:25

From ?barplot:

space: the amount of space (as a fraction of the average bar width) left before each bar. May be given as a single number or one number per bar. [...]

So, for example, compare:

tN <- table(Ni <- stats::rpois(100, lambda = 5))
barplot(tN, col = rainbow(20))

barplot(tN, col = rainbow(20), space=0)

barplot(tN, col = rainbow(20), space=10)
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!