繁体   English   中英

如何在R中的twoord.plot中旋转Y轴标签?

[英]How to rotate Y axis labels in twoord.plot in R?

有谁知道如何在R中的twoord.plot函数中旋转Y轴标签? 另外,如何调整Y轴标签的字体大小?

在同等条件下:我只是选择了twoord.plot包随附的随机图。

 x <- rnorm(100,100,10)

首先,您需要旋转Y轴:

 par(las = 1) # rotates the y axis values for every plot you make from now on unless otherwise specified

接下来,绘制没有Y轴的图形:

 plotH(x,x,yaxt = 'n') # no Y axis

然后,您需要添加Y轴

  axis(2,cex.axis = 0.5) # where 2 specifies the Y axis and 0.5 is half (0.5) of the font size as before.

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM