Same function in different libraries in R




Suppose a function with a particular name is present in more than one packages, and we load both of these packages. Now if one package is an iteration of the other like plyr and dplyr, the function would most probably do the same work in both the packages. But what if it performs different functions in different packages?
What would happen if we use the function after loading both the packages? Will it work according to the syntax in the particular package or will give an error?



Why not give it a try and see what happens? (That’s a serious suggestion, by the way. You’d get the answer faster that way and also get to explore the nuances of the language. :smile: )