The start or end of a string.
START
matches the start of a string.
END
matches the end of a string.
exactly
makes the regular expression match the whole string, from
start to end.
START END exactly(x)
x |
A character vector. |
An object of class regex
(inherits from character
) of length 1.
A character vector representing part or all of a regular expression.
Caret and dollar are used as start/end delimiters, since \A
and
\Z
are not supported by R's internal PRCE engine or stringi
's
ICU engine.
START END # Usage x <- c("catfish", "tomcat", "cat") (rx_start <- START %R% "cat") (rx_end <- "cat" %R% END) (rx_exact <- exactly("cat")) stringi::stri_detect_regex(x, rx_start) stringi::stri_detect_regex(x, rx_end) stringi::stri_detect_regex(x, rx_exact)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.