[R] Data frame: how to create list of row max?

David Barron mothsailor at googlemail.com
Mon Feb 19 13:42:01 CET 2007


Try do.call("pmax",c(dataframe[,intensityindices],na.rm=TRUE))

This is like the second example in the help page for do.call

On 19/02/07, Johannes Graumann <johannes_graumann at web.de> wrote:
> On Monday 19 February 2007 11:53, Prof Brian Ripley wrote:
> > do.call("pmax", dataframe[,intensityindeces])
> Thank you very much for your help!
>
> Any idea why do.call("pmax",list(na.rm=TRUE),dataframe[,intensityindeces])
> would give me
>
> Error in if (quote) { : argument is not interpretable as logical
> In addition: Warning message:
> the condition has length > 1 and only the first element will be used in: if
> (quote) {
>
> ?
>
> Thanks, Joh
>
> ______________________________________________
> R-help at stat.math.ethz.ch 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.
>
>
>


-- 
=================================
David Barron
Said Business School
University of Oxford
Park End Street
Oxford OX1 1HP



More information about the R-help mailing list