Читать книгу The Big R-Book - Philippe J. S. De Brouwer - Страница 239

Digression – Calling methods of not loaded packages

Оглавление

When a package is not loaded, it is still possible to call its member functions. To call a function from a certain package, we can use the :: operator.

In other words, when we use the :: operator, we specify in which package this function should be found. Therefore it is possible to use a function froma package that is not loaded or is superseded by a function with the same name from a package that got loaded later.

R allows you to stand on the shoulders of giants: when making your analysis, you can rely on existing packages. It is best to use packages that are part of the tidyverse, whenever there is choice. Doing so, your code can be more consistent, readable, and it will become overall a more satisfying experience to work with R.

The Big R-Book

Подняться наверх