Description Usage Arguments Details Value Author(s)
Find a Partial or Exact Match from a Vector of Strings Searches a vector of character-string, and returns the best match.
1 | find.match(needle, haystack, fail = NA)
|
needle |
a character-string to search for in the |
haystack |
a vector of character-strings |
fail |
the value to return in case no match is found. Defaults to NA |
“find.match” attempts to use several common matching functions in an order that sequentially prefers less strict matching, until a suitable match is found. If none is found, then return the value of the “fail” parameter (defaults to NA). The functions used for matching are: “match”, “charmatch”, and finally “grep”.
the best-matched string or NA
Matt Owen mowen@iq.harvard.edu
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.