简体   繁体   English

在plot.zoo r中将我的y轴数取整

[英]Round the number of my y axis in plot.zoo r

Good morning, i have the next code: 早上好,我有下一个代码:

plot.zoo(ResultadosLP, plot.type="m", ylab = c("Spread", "Mid_Rqs", "L_Rqs",                                          "Mid_QP","Ef_Spread","Mid_Res",                                               "L_Res", "IRC"), cex.axis=0.65,xlab = "Fecha(periodicidad mensual)"

I want to round the numbers of my axis y because I got 4 digits, and I need only one digit in the plot, how can I do that? 我想对y轴的数字进行四舍五入,因为我得到了4位数字,并且在图中只需要一位数字,我该怎么做? Note: it is a multiplot, and if you could give me other advice to solve the problem of size, I appreciate so much that. 注意:这是多幅图,如果您能给我其他解决尺寸问题的建议,我非常感谢。 I tried cex.axis , but I can't keep going because is too small. 我尝试了cex.axis ,但是因为太小而无法继续前进。

Thanks 谢谢

Try calling signif() on the variables in ResultadosLP you're plotting on the y-axis before you plot it. 尝试在y轴上绘制的ResultadosLP的变量上调用signif() You can set the argument digits = 2 您可以设置参数digits = 2

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

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