Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.snow at imail.org
801.408.8111
> -----Original Message-----
> From: r-help-bounces at r-project.org [mailto:r-help-bounces at r-
> project.org] On Behalf Of rkevinburton at charter.net
> Sent: Monday, January 12, 2009 5:55 PM
> To: r-help at r-project.org
> Subject: [R] pmax and sort?
>
> I am having a hard time understanding the documentation and I was
> wondering if there would be someone to help clear the cobwebs.
>
> The documentation for pmax states:
>
> pmax and pmin take one or more vectors (or matrices) as arguments and
> return a single vector giving the ?parallel? maxima (or minima) of the
> vectors. The first element of the result is the maximum (minimum) of
> the first elements of all the arguments, the second element of the
> result is the maximum (minimum) of the second elements of all the
> arguments and so on. Shorter inputs are recycled if necessary.
> attributes (such as names or dim) are transferred from the first
> argument (if applicable).
>
> This descirption seems to me like what sort would return. Would someone
> please help me understand the differenece between pmax and sort?
>
> Thank you.
>
> Kevin
>
> ______________________________________________
> 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.