[R] Re: or of a logical vector

Jeff Gentry jgentry at jimmy.harvard.edu
Thu Aug 5 21:05:41 CEST 2004

> Is there some fast (built-in?) way to get the OR of all the elements in
> a logical vector?

any() and all() should give you OR and AND, respectively.  Perhaps this
should be in as a 'see also' for '|' and '&'.


More information about the R-help mailing list