Convert coordinates from degree-minute-decimal to decimal degree
ss_coords_from_ddm_to_dd.Rd
To apply to multiple columns using dplyr::across
:
Details
1. Define variables to convert:
coords_ddm <- c("deployment_latitude_n_ddm", "deployment_longitude_w_ddm", "retrieval_latitude_n_ddm", "retrieval_longitude_w_ddm")
2. Use the .names argument to specify new column names so that the original columns are not over-written:
dat <- dat_raw ~ss_coords_from_ddm_to_dd(.x), .names = "str_remove(.col, '_w_ddm|_n_ddm')" ))