-
Notifications
You must be signed in to change notification settings - Fork 20
Loading tidyverse package: Conflicts with tidy/dplyr messages? #331
Comments
When you load a package, if functions in the library share names with any base R functions or any other functions in loaded packages they warn you of the conflict and they replace them as the default function that will be called when you write their names. Functions with names filter and lag exist in base R which means they will always conflict with dplyr functions. Normally when making packages, you don't want to give your functions the same names as anything that is in base R or any popular packages as this would cause confusion and annoyance to users, but I assume Hadley (creator of dplyr) doesn't think you'd be using base R's filter or lag when you have load dplyr since they do more or less the same thing. When a conflict happens, in order to use the functions that were "masked" you need to do packageName::functionName, in this case stats::filter or stats::lag |
Yes this is normal. I was getting that too. Better reporting of conflicts is, in fact, one of the motivations for making the tidyverse meta-package. As @oganm says, this is your incessant reminder that, if you want to access one of those masked functions, you will need to do so with explicit namespace qualification as he shows: |
Got it! Thanks for the really prompt responses!! |
For some weird reason, dplyr's |
Output in my console when I load tidyverse in a new R session.
Is this a normal "conflict" message re. tidy packages?
The text was updated successfully, but these errors were encountered: