Skip to content

Windows-specific: image(z,zlim=()) gives bogus colors outside range (PR#525)

4 messages · Ben Bolker, Uwe Ligges, Thomas Lumley

#
In the Windows version of R (not in the equivalent version
running on Linux RH 6.0), doing image(z,zlim=c(a,b)) with
non-trivial limits (i.e., smaller than the range of z)
plots bogus colors (randomly picked from the colormap,
perhaps?) in regions where z is outside of zlim.  (on the
Linux version those regions are just plotted in black, which
seems more appropriate)

  For example:

x <- seq(-1,1,length=50)
z1 <- expand.grid(x,x)
z2 <- matrix(apply(z1,1,function(x)sum(x^2)),nrow=50)
image(z2,zlim=c(0.5,1.5))


--please do not edit the information below--

Version:
 platform = Windows
 arch = x86
 os = Win32
 system = x86, Win32
 status = 
 major = 1
 minor = 0.0
 year = 2000
 month = February
 day = 29
 language = R

Windows 9x 4.0 (build 1212)  B

Search Path:
 .GlobalEnv, Autoloads, package:base
#
Oops, I take it back.  I *thought* it worked on Linux, but I just tried
it and got the same problem -- and I get the segmentation fault on Linux
too.
On Wed, 19 Apr 2000, Uwe Ligges wrote:

            

  
    
#
bolker@zoo.ufl.edu schrieb:
Additionally try

  image(z2,zlim=c(0.5,0.500001))

Gives segmentation fault on Solaris / Dr. Watson on WinNT

Regards, 
Uwe Ligges
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
#
On Wed, 19 Apr 2000, Ben Bolker wrote:

            
This seems to have been fixed in the development branch at least.

	-thomas

Thomas Lumley
Assistant Professor, Biostatistics
University of Washington, Seattle


-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._