叶和茎图与布局功能不兼容
我正在尝试使用布局功能连接 4 个图表。然而,我只得到了 3 个表示:除了茎叶图之外的所有图。
简而言之,这就是 r 中的样子:
layout(matrix(c(1,2,3,4), 2, 2, byrow =TRUE))
stem(graph1)
boxplot(graph2)
hist(graph3)
barplot(graph4)
为什么茎图的绘制与其他图不同,是否有另一个函数可以做到这一点?
先感谢您
I am trying to join 4 graphs with the layout function. However, I only get 3 represented: all except the stem and leaf diagram.
In brief, this is what it looks like in r:
layout(matrix(c(1,2,3,4), 2, 2, byrow =TRUE))
stem(graph1)
boxplot(graph2)
hist(graph3)
barplot(graph4)
Why doesn't the stem graph plot the same as the others, and is there another function that can do it?
Thank you in advance
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
正如@davearmstrong已经暗示的那样,
stem
输出字符,这些字符可打印但不可绘制。您可以将输出从
stem
重定向到类似的图(无耻地从 this So Anders ):As @DaveArmstrong already hinted,
stem
outputs characters, which are printable but not plotable.You could redirect the output from
stem
to a plot like so (shamelessly stolen from this SO answer):