sub_regex: Substitute regular expressions within a vector with another...

Description Usage Arguments Value

View source: R/sub.R

Description

sub_value finds regular expressions within x specified by from and substitutes them with strings specified in to. Regexs specified by from will be replaced in a 1:1 or many:1 fashion. Only regexs within from that are contained in x will be replaced.

Usage

1
sub_regex(x, from, to)

Arguments

x

A character vector, that will be searched for a collection of regular expressions (specified to) replaced by strings specified in from.

from

A vector of regexs potentially contained within x that are to be substituted

to

The corresponding strings that will be used to replace elemnts of from. converted to

Value

A character vector, derived from x, will have 0 or more elements altered based on the specified from:to mapping


graggsd/sgcleanup documentation built on May 28, 2019, 8:53 p.m.