minimal <- construct("a", "b", "c")
minimal
subs(minimal)
subs(minimal)[2] <- "\\s+[A-Z]|[0-9]"
subs(minimal)
minimal <- construct("a", "b", "c")
out <- set_subs(minimal, c("(", "\\s??", ")"))
subs(out)
Run the code above in your browser using DataLab