Arrange common plot width with facetted ggplot 2.0.0 & gridExtra

后端 未结 4 1280
余生分开走
余生分开走 2021-01-02 23:22

Since I have updated to ggplot2 2.0.0, I cannot arrange charts propperly using gridExtra. The issue is that the faceted charts will get compressed while other will expand. T

4条回答
  •  猫巷女王i
    2021-01-02 23:54

    Taking off these two lines and keeping the rest, it worked just fine.

    g.iris$widths <- max.widths # assign max. widths to iris gtable
    g.mpg$widths <- max.widths # assign max widths to mpg gtable
    

    Probably it was limiting the width of them.

提交回复
热议问题