gsub_multi_pattern: Substitute from a vector of patterns with a single...

View source: R/regex_tools.R

gsub_multi_patternR Documentation

Substitute from a vector of patterns with a single replacement

Description

Substitute from a vector of patterns with a single replacement

Usage

gsub_multi_pattern(x, patterns, replacement, ..., verbose = FALSE)

Arguments

x, replacement

See gsub

patterns

A vector of patterns as used individually in gsub and grepl

...

Passed to gsub and grepl

verbose

Signal messages with the count of values that matched each pattern or no pattern.

Value

A vector of NA_character_ when no match occurs and the replaced value when a match occurs.

See Also

grepl_multi_pattern


billdenney/bsd.report documentation built on Jan. 16, 2024, 12:54 a.m.