Description Usage Arguments Details Value Author(s) References See Also Examples
These functions test set relations using binary operators. See details.
1 2 3 4 5 6 7 8 |
x |
left operand |
y |
right operand |
mode |
currently ignored |
The function %+%
and its alias %u%
give set union, with obvious mnemonic significance.
%&%
gives set intersection; mnemonically, elements present in x and y.
n
looks like an inverted u
in many fonts, so %n%
gives set intersection
in something more like classical notation. %-%
is suggestive of set difference
both in arithmetic and classical notation.
These functions call union
, intersect
, and setdiff
, which
coerce their arguments to vector. For convenience, as.vector.keyed
is defined
to return just the names of a keyed data frame – frequently these are subject to set manipulations.
vector
Tim Bergsma
http://metrumrg.googlecode.com
union
intersect
setdiff
1 2 3 4 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.