Why do I get a notice of Conflicts for the filter() function in dplyr when loading tidyverse?

I learned that library() conflicts can occur when functions in two different packages have the same name, and in such cases, the functions from the last package loaded are the ones RStudio will use.

Does that mean when I get this notice of conflict with dplyr's filter function when loading tidyverse, I need to next load dplyr on its own, after loading tidyverse?


The warning is telling you that dplyr::filter() is masking the base R function stats::filter() so no need to do anything else. Have in mind that filer() comes fromdplyr not from tidyverse, the latest is just an aggregator for a family of packages that get loaded together.

OK, so what's listed on the left is what will be used, and what comes after "masks" won't. Great! Thanks so much! :grinning:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.