[R] Limiting size of pairs plots
Sébastien
pomchip at free.fr
Tue Aug 28 13:11:31 CEST 2007
Dear R-users,
I would like to add a legend at the bottom of pairs plots (it's my first
use of this function). With the plot function, I usually add some
additional space at the bottom when I define the size of the graphical
device (using mar); grid functions then allows me to draw my legend as I
want.
Unfortunatley, this technique does not seem to work with the pairs
function as the generated plots use all the available space on the
device (see below). I guess I am missing a key argument... my attempts
to modify the oma, mar, usr arguments were unsuccesfull, and I could not
find any helpful threads on the archives.
As usual, any advice would be greatly appreciated
Sebastien
pdf(file="C:/test.pdf", width=6, height= 6 + 0.2*6)
par(mar=c(5 + 6,4,4,2)+0.1)
pairs(iris[1:4], main = "Anderson's Iris Data -- 3 species", pch = 21,
bg = c("red", "green3", "blue")[unclass(iris$Species)])
dev.off()
More information about the R-help
mailing list