[R] png() and/or jpeg(): line missing by using box(which="outer")
Prof Brian D Ripley
ripley at stats.ox.ac.uk
Tue Oct 21 13:32:05 CEST 2003
It is probably a bug: does it happen when you copy from the screen in png?
I would expect not, hence that may be a workaround for you.
When I have both time and access to a Windows machine I may be able it take
a closer look: meanwhile you do have access and have the source code so
please investigate it yourself and submit a patch.
On Tue, 21 Oct 2003, Pfaff, Bernhard wrote:
> 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.
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://www.stat.math.ethz.ch/mailman/listinfo/r-help
>
>
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272860 (secr)
Oxford OX1 3TG, UK Fax: +44 1865 272595
More information about the R-help
mailing list