creating a pdf in R that is vertically justified
Question: how can you create a pdf where the output is vertically
justified, with for example, a one inch margin on top using pdf()
.
For example in
pdf(file='test.pdf', paper='letter', pagecentre=F)
### code for plot here ###
dev.off()开发者_JAVA技巧
is there an option where it generate output that starts from the top of the
page rather than printing from the bottom of the page (which is what happens when pagecentre=F
). Or will this require
some adjustment of settings in par()
?
I always use
pdf(file="/tmp/foo.pdf", width=10.5, height=8)
plot(....)
dev.off()
which nicely fills the page with just 1/2 inch spacing. You can flip width and height arguments to go to 'portrait' rather than 'landscape'.
精彩评论