Skip to content

Instantly share code, notes, and snippets.

@randrescastaneda
Created June 24, 2020 19:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save randrescastaneda/69008ad164b50778cbd4c0896cd8d982 to your computer and use it in GitHub Desktop.
Save randrescastaneda/69008ad164b50778cbd4c0896cd8d982 to your computer and use it in GitHub Desktop.
Find which names of variables in one dataframe x are in equal to the names in dataframe y
equ_names <- function(x, y) {
nms <- names(x)[names(x) %in% names(y)]
return(nms)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment