Saturday, 24 August 2013

Multiple lattice plots with gridExtra

Multiple lattice plots with gridExtra

There is very convenient way of plotting multiple graphs and that's with
gridExtra - grid.arrange:
grid.arrange(plot1,plot2,plot3,plot4,plot5,plot6,plot7,plot8,plot9, ncol=3)
The above command draws 3x3 graphs in one window.
Now, I'm using my own lattice setup to draw unique lines etc. via
trellis.par.set(my.setup)
However using the grid.arrange command for plotting multiple plots won't
pass on the setup as the output plots are in default colours.
So the question is how to pass on the my.setup onto grid.arrange or
alternatively how to plot easily multiple graphs in one go for lattice.

No comments:

Post a Comment