regex_match | R Documentation |
Returns elements of a character vector that match the given regular expression
regex_match(regex = NULL, vector = NULL, silent = FALSE, perl = FALSE)
regex |
a regular expression provided, a default theme will be used. |
vector |
a character vector in which to search for regular expression matches, or a data table whose column names will be searched |
silent |
logical. If |
perl |
logical. Should Perl-compatible regexps be used? |
regex_match("p$", names(mtcars))
colnames_ending_with_p <- regex_match("p$", names(mtcars))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.