Improve regex pattern gsub("\\s*\\([^)]*\\)", "", ...) it captures any text in parentheses regardless of content
gsub("\\s*\\([^)]*\\)", "", ...)