[R] png() and/or jpeg(): line missing by using box(which="outer")

Pfaff, Bernhard Bernhard.Pfaff at drkw.com
Tue Oct 21 13:04:18 CEST 2003


Dear R list,

I do encounter the following problem by generating either a png-file
(example below) or a jpeg-file: 
By employing 'box(which="outer")' a box is drawn, except for the right line.
If I generate the plot without the 'box(which="outer")', a line at the
bottom in the graphics file still appears. However, both plots are displayed
correctly in the R Graphics Device Window, i.e  with a box including the
right side or one without any lines at the outer margins of the plot. Now, I
want either a file - including the right side of box or one that has none on
all sides. 

test <- rnorm(100)
par(mar=c(6,4,6,4), oma=c(1,1,1,1))
png("test1.png")
plot(test)
grid()
box(which="outer")
box(which="plot")
dev.off()

png("test2.png")
plot(test)
grid()
box(which="plot")
dev.off()

Incidentally, both functions are calling .Internal(devga(....)). I have not
encountered this problem with version R 1.7.1 (for which I used the binary
distribution on CRAN). Now, I have source compiled R 1.8.0. Although,
everything passed 'make check', I am wondering if it could be possible that
'devga.c' or any other necessary file for running png() or jpeg() have not
been compiled 'correctly', or do I have simply to adjust a par()-argument?  

Any pointers or help is appreciated.
 

Bernhard


platform: "i386-pc-mingw32"
arch: "i386"
os: "mingw32"
system: "i386, mingw32"
major: "1"
minor: "8.0"
Windows NT 5.0



--------------------------------------------------------------------------------
The information contained herein is confidential and is intended solely for the
addressee. Access by any other party is unauthorised without the express
written permission of the sender. If you are not the intended recipient, please
contact the sender either via the company switchboard on +44 (0)20 7623 8000, or
via e-mail return. If you have received this e-mail in error or wish to read our
e-mail disclaimer statement and monitoring policy, please refer to 
http://www.drkw.com/disc/email/ or contact the sender.




More information about the R-help mailing list