Description Usage Arguments Value Examples
R (data.table) lacks a negation of the %like% operator. While you can negate the whole expression, that solution results in less readable and clear code.
1 2 3 4 5 | unlike(.vector, .pattern)
.vector %unlike% .pattern
.vector %notlike% .pattern
|
.vector |
Either a character vector or a factor. |
.pattern |
Gets passed on to |
Logical vector of same length as .vector
. TRUE
if the input value
matches the pattern (via regular expression matching). FALSE
otherwise.
1 | "ana" %like% c("Anabelle", "banana", "BanAna", "meh")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.