escape {rex} | R Documentation |
Escape characters for a regex
escape(x) ## S3 method for class 'regex' escape(x) ## S3 method for class 'character_class' escape(x) ## S3 method for class 'character' escape(x) ## Default S3 method: escape(x) ## S3 method for class 'list' escape(x)
x |
Object to escape. |
regex
: Objects are simply passed through unchanged.
character_class
: Objects are surrounded by braces.
character
: Objects are properly escaped for regular expressions.
default
: default escape coerces to character and escapes.
list
: simply call escape on all elements of the list.