Tag: replace values with dplyr mutate
Use R dplyr mutate to add and remove existing columns
The main purpose of the function mutate from dplyr is to add a new variable with necessary calculations. Here is how to use the mutate to add and remove existing data frame columns if they are not necessary. It will help you to eliminate extra steps in your data-wrangling process.