I had a dataframe where I recoded several columns so that 999 was set to NA
dfB <-dfA %>% mutate(adhere = if_else(adhere==999, as.numeric(NA), adhere
Now that funs has been depreciated in dplyr, here's the new way to go:
funs
z <- y %>% mutate_if(is.integer, as.numeric) %>% mutate_at(vars(y1:y2), list(~recode(.,`999` = NA_real_)))
Replace funs with list and insert a ~ before recode.
list
~
recode