[36] in mathematical software users group
graphics() in x11()
daemon@ATHENA.MIT.EDU (daemon@ATHENA.MIT.EDU)
Fri Apr 10 12:01:34 1992
From: pevzner@clockwise.att.com
Date: Fri, 10 Apr 11:59:22 1992
To: S-news@stat.wisc.edu
Cc: afh@Athena.MIT.EDU, htan@Athena.MIT.EDU, pevzner@Athena.MIT.EDU,
Reply-To: clockwise!pevzner@clockwise.att.com
I am sorry if this happens to be a FAQ, but I did not see anybody
asking this question lately.
I am using AT&T S (New S) in the X environment, using x11() for
displaying graphics. I expect
> plot(1:10)
to produce the same result as
> print(graphics(plot(1:10)))
or, alternatively, in a normal S usage, the same as
> g <- graphics(plot(1:10))
> g
Unfortunately, it does not seem to be the case in x11()
(although all three expressions do indeed work identically, as expected,
in tek4014() and postscript().)
In x11(), plot(...) produces a normal graph with normal axes, just as it's
supposed to. However, print(graphics(plot(...),...)) draws an external
box, a graph in the coordinate system of that box, and then some strange
scaled down axes inside the box, which have nothing to do with the plot
itself.
I tried a few S compilations here at Bell Labs and at M.I.T., and all
seem to behave as described above. I was told that Splus complains
(spits out some error message) if given a print(graphics(plot())) command.
Am I seriously missing something, or it's a bug in x11()?
If it's a bug, has someone developed a workaround?
Thanks very much,
-Boris Pevzner
pevzner@clockwise.att.com
(908)582-6022