I'm trying to extract the digits and letters following "not" but I don't want to retrieve "not". I know how to do it in Perl or Go, but I'm missing something in R.
Example:
x = "not ab300c_7787 or not ab300c_7038 and not ab300c_7312"
str_extract_all(x1, "not [:word:]+")
returns "not ab300c_7787" "not ab300c_7038" "not ab300c_7312" but I want "ab300c_7787" "ab300c_7038" "ab300c_7312"
Is there an easy way to do this in R?
Thanks.