-----Original Message-----
From: baron@cattell.psych.upenn.edu
[mailto:baron@cattell.psych.upenn.edu]
Sent: Friday, January 31, 2003 12:37 PM
To: r-devel@stat.math.ethz.ch
Cc: R-bugs@biostat.ku.dk
Subject: [Rd] minor error in documentation of pmax in base (PR#2513)
The documentation says, "pmax and pmin take several vectors as
arguments and return a single vector giving the parallel maxima
(or minima) of the vectors."
I discovered that, if you use a matrix or array instead of a
vector, pmax returns a matrix or array, respectively.
This makes pmax and pmin much more useful, and should not be left
to people to discover on their own!
For example:
m1 <- array(1:24,c(2,3,4))
m2 <- array(24:1,c(2,3,4))
pmax(m1,m2)
pmin(m1,m2)
Jon Baron