Reputation: 705
I cannot get the layout command to work. I want a multi-panel plot with a gap in a specific position, as given by this matrix:
mat <- matrix (c(1,2,3,4,5,6,7,8,9,10,0,12), 4, 3)
mat
where value 0 represents where I need empty space. However I get an error message when I run
layout(mat)
Using the following does not work either
mat <- matrix (c(1,1,1,1,1,1,1,1,1,1,0,1), 4, 3)
because when I run
layout.show(12)
it only gives me one panel instead of a 3x4 matrix layout. Where am I going wrong?
Thanks!
Upvotes: 1
Views: 32
Reputation: 12664
The issue is that you have a number 12 panel, but no number 11. Try this instead
mat <- matrix (c(1,2,3,4,5,6,7,8,9,10,0,11), 4, 3)
layout(mat)
layout.show(11)
Upvotes: 2