Use the gsub() function to replace matches determined by regular expression matching. The sub() function is the same but only replaces the first occurrence.
Use the gsub() function to replace matches determined by regular expression matching. The sub() function is the same but only replaces the first occurrence.