rmrp {textutils} | R Documentation |
Remove Repeated Pattern
Description
Remove a repeated pattern in a character vector.
Usage
rmrp(s, pattern, ...)
Arguments
s |
a character vector |
pattern |
a regular expression |
... |
arguments passed to |
Details
rmrp
removes a repeated pattern in a character vector (e.g.
repeated blank lines).
Value
a character vector
Author(s)
Enrico Schumann
See Also
Examples
## remove repeated blanks from vector
s <- c("* Header", "", " ","", "** Subheader")
rmrp(s, "^ *$")
[Package textutils version 0.4-1 Index]