1

I need to merge 3 graphs into one grid in a dashboard. I have three objects as p1, p2, and p3. I need p1 and p2 to be on the top covering 20% width and center on the top next to each other. And p3 to be on the bottom, covering 80% of the height and 100% of the width:

I have this:

grid.arrange(p1, p2, p3, widths=c(300, 300, 1000), heights=c(300,300,700),ncol=2, clip=TRUE)

display is not balanced p2 seems greater that p1 and p3 is small not as I expected. Any ideas?

user1471980
  • 10,127
  • 48
  • 136
  • 235
  • @JoshO'Brien Indeed, I missed that. – joran Mar 01 '13 at 21:11
  • @JoshO'Brien, @Joran, I'm not sure if the two questions are the same. Here, the OP is asking how specifically to adjust the parameters of `grid.arrange` to obtain the desired results – Ricardo Saporta Mar 01 '13 at 21:19
  • 3
    @RicardoSaporta -- Something like `library(gridExtra); library(lattice); a <- b <- c <- xyplot(1:10 ~ 1:10); grid.arrange(arrangeGrob(a,b, ncol=2), c, heights=c(0.2, 0.8))` does everything the OP asks for, I think. – Josh O'Brien Mar 01 '13 at 21:44
  • I was ablet o figure this out. Can you have this as an answer and I will accept it? – user1471980 Mar 04 '13 at 15:01

0 Answers0