replace_xy | R Documentation |
Replace NA in .x cols by .y cols (or vice versa) after incomplete *_join
replace_xy(tbl, vars = NULL, ending_to_keep = ".x")
tbl |
A tibble or data_frame |
vars |
By default, the function searches for variables with .x/.y suffixes.
Alternatively, a character vector of names of variables that are duplicated
can be provided. This is useful when operating with |
ending_to_keep |
Choose which column suffix should be kept for rows where both columns have values. Currently only implemented for .x/.y. |
A tibble with merged columns
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.