[R] clipping viewports

jiho jo.irisson at gmail.com
Mon Oct 1 09:19:53 CEST 2007


On 2007-October-01  , at 08:42 , Paul Murrell wrote:
> Mikkel Grum wrote:
>> Dear useRs,
>>
>> Why are the rotated blue and yellow boxes in the example below  
>> clipped outside of 6 x 6 inch window in the middle of the page??  
>> Where does the 6 x 6 inch window come from? I would like to make  
>> use of the entire page.
>
>
> 6x6 corresponds to the default size of the pdf() device, so it looks
> like an issue with the implementation of paper="a4".  Indeed, this
> variation works as expected for me ...
>
> pdf(file = "FarmMaps.pdf", width=7.6, height=11)
>
> I will look at why the original approach does not work.

I have been bitten by this several times already. From what I  
understood, the 'paper' argument just specifies the size of the sheet  
on which a device of size 'width'x'height' is printed. The only  
relations between the paper argument and the device size arguments are:
- when using the default size "special"
- when the device size is > paper size, in which case the device is  
resized to fit on the paper sheet
I would also like the device to take the full sheet when using the  
paper argument, unless overridden by specific width and height  
arguments.

JiHO
---
http://jo.irisson.free.fr/



More information about the R-help mailing list