regex_match_except: Return characters not matching a regular expression

Description Usage Arguments Value

View source: R/haircut.R

Description

Given a vector of chracter strings, this function returns portions of the stirng that do not march a pattern, as a vector. This allows a chainable regex filtering style that is readily compatible with ' Capturing groups, '()', will create an error since they generate multiple matches that do not have a sensible inverse. Best to use non-capturing '(?:)'.

Usage

1

Arguments

text

a vector of characer strings to be (un)matched.

pattern

a regular expression.

Value

vector of substrings of 'text' that dit not match the 'pattern'.


MilesMcBain/haircut documentation built on May 21, 2019, 2:31 a.m.