[R] par(mfrow=c(3,4)) problem

Sarah Goslee @@r@h@go@lee @ending from gm@il@com
Wed May 30 11:03:56 CEST 2018


Hi,

You're mixing base plot and ggplot2 grid graphics, which as you've
discovered doesn't work.

Here's av strategy that does:
https://cran.r-project.org/web/packages/egg/vignettes/Ecosystem.html

This vignette has a good overview, well as info specific to that package.

Sarah


On Wed, May 30, 2018 at 4:43 AM greg holly <mak.hholly using gmail.com> wrote:

> Hi all;
>
> I need to put 12 different plot2 into the same matrix. So my array for the
> matrix will be par(mfrow=c(3,4)).  I am running ggplot2 to produce my 12
> plots. For some reason, par(mfrow=c(3,4)) did not turn out 3*4 matrix.
>
> my basic R codes for each plot is
> par(mfrow=c(3,4))
> library(ggplot2)
> p <- ggplot(a, aes(x=Genotypes, y=Plant_hight, size=Plant_hight,
> color=Showing_rate)) +
> .
> .
>
> Best regards,
>
> Greg
>
>         [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help using r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
-- 
Sarah Goslee
http://www.stringpage.com
http://www.sarahgoslee.com
http://www.functionaldiversity.org

	[[alternative HTML version deleted]]



More information about the R-help mailing list