[R] several image.plots with same axis (maximum)

From: <mdgi_at_gmx.ch>
Date: Fri, 25 Jan 2008 07:55:02 +0100


Hello R freaks

I have the following problem:

I have several image plots, that need to have the same axis. i want to specify the range from 0 to a maximum value. The problem is, that the axis then only goes to the highest value of the respective plot. E.g: this is a modified example from the help file "image.plot" z values go until 25. My maximum in plot two is set to 30, so I want the first one to be the same range:

par(mfrow=c(1,2))

x<- 1:10; y<- 1:15; z<- outer( x,y,"+") #define array whiteblack = colorRampPalette(c("white", "black"), space = "Lab") #color image.plot(x,y,z, legend.lab="inches",col=whiteblack(30), breaks=seq(0,30,1)) #image.plot with breaks from 0 to 30

x<- 1:10; y<- 1:15; z<- outer( x,y+5,"+") whiteblack = colorRampPalette(c("white", "black"), space = "Lab") image.plot(x,y,z, legend.lab="inches",col=whiteblack(30), breaks=seq(0,30,1))

Thanks a lot for your help

Mike

-- 
Ist Ihr Browser Vista-kompatibel? Jetzt die neuesten

______________________________________________
R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Received on Fri 25 Jan 2008 - 06:57:15 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Fri 25 Jan 2008 - 07:30:08 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive