通过使用ggplot函数和基本绘图函数获得相同的绘图

时间:2016-11-15 05:28:21

标签: r plot knitr r-markdown

我通过rmarkdown unsing knitr(html_document)记录分析过程。

我逐个使用ggplot2::ggplot()graphics::plot() 但是图形尺寸字体大小,绘图区域不同。

我想使用两个情节函数获得相同的情节 颜色,轴,......都没问题。 我怎么设置?

我希望能够轻松简化设置,就像只编写块设置一样。

ggplot(iris, aes(Sepal.Length, Petal.Length)) + geom_point()

plot(Petal.Length ~ Sepal.Length, data = iris)

0 个答案:

没有答案