Learn R Programming

lettercase (version 0.13.1)

str_delete: str_delete

Description

Delete or remove characters from a string based on one or more patterns

Usage

str_delete(string, ...)

Arguments

string
atomic character vector
...
stringr-style matching modifiers

Details

Deletes all occurences of the patterns from the string using str_replace_all

References

modifiers str_replace_all

Examples

Run this code
str_delete( "ABC & 123", stringr::regex("\\W") )  # ABC123

Run the code above in your browser using DataLab