如何在条形图中查看类别的名称?

How can I see the name of the categories in the barplot?

如何让字母变小以查看不同类别的全名? (如果我做一个“情节”而不是“条形图”,我只能看到所有的名字)

我们的想法是制作一个 ** 条形图 **,其中包含 4 个类别的全名(您可以在下面的图形“图”中看到)。

plot(table(somalia$strike_status))

barplot(table(somalia$strike_status))

谢谢。

您可以使用参数 cex.names(作为调用 barplot 的参数之一)定义 x 轴上名称的字符扩展。例如,如果您设置 cex.names = 0.5,这会将字符的大小减小为默认大小的一半,从而使它们在绘图中更容易看到。