out: The Opposite of '%in%'

Description Usage Arguments Details Value Author(s) See Also Examples

Description

Duh.

Usage

1
x %out% y

Arguments

x

vector or NULL: the values to be matched.

y

vector or NULL: the values to be matched.

Details

That %out% never returns NA makes it particularly useful in if conditions.

Value

A logical vector of the same length as x, indicating if a match was located for each element of x: thus the values are TRUE or FALSE and never NA.

Author(s)

Antoine Filipovic Pierucci

See Also

match. pmatch and charmatch for (partial) string matching, match.arg, etc for function argument matching. findInterval similarly returns a vector of positions, but finds numbers within intervals, rather than exact matches.

Examples

1
2
1:5 %out% 3:6
letters[letters %out% c("a", "b")]

rmngb documentation built on May 29, 2017, 9:22 p.m.

Related to out in rmngb...