Closed Maleeha closed 4 years ago
In reference to the example in issue #11:
pax <- c("asdgf2", "asd3", "bcdfs4", "zsdfs5", "asdfs6", "podf-podf-podf-podf-podf")
regex <- "(^\D\D\D\D)|-\D\D\D\D|(^\D+)3"
- `grep` returns terms that contain matches:
grep(regex, pax, value=T) [1] "asdgf2" "asd3" "bcdfs4" "zsdfs5" [5] "asdfs6" "podf-podf-podf-podf-podf"
- `grepl` returns whether the "terms with matches" are `TRUE` or `FALSE`
grepl(regex, pax) [1] TRUE TRUE TRUE TRUE TRUE TRUE
Thanks again for the review @wibeasley
correct.
In reference to the example in issue #11:
regex <- "(^\D\D\D\D)|-\D\D\D\D|(^\D+)3"
Thanks again for the review @wibeasley