Return lhs values not in rhs values

nin(lhs, rhs, value = TRUE)

yin(lhs, rhs, value = TRUE)

Arguments

lhs

Values to check whether they are/not contained in the other

rhs

Values to use as the reference

value

Logical indicating whether to return the value or a logical vector

Examples

## a, b, zz in alphabet letters yin(c("a", "b", "zz"), letters)
#> [1] "a" "b"
## a, b, zz NOT in alphabet letters nin(c("a", "b", "zz"), letters)
#> [1] "zz"