Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Turn off verbose messages when loading tidyverse using library() function

Tags:

r

tidyverse

How does one turn off the many lines of messages when loading tidyverse in R? It doesn't respect the quietly parameter (e.g., library(tidyverse, quietly = TRUE)). Sometimes I might want to see all of the packages it attaches and conflicts, but most of the time I can do without it or would like a less obnoxious report. Any hints on how to do this?

I'm using tidyverse 1.2.1 under R 3.4.3 on macOS 10.12.6, but am guessing this is same behavior on other systems.

like image 806
Rick Donnelly Avatar asked Feb 02 '18 16:02

Rick Donnelly


Video Answer


2 Answers

suppressPackageStartupMessages(library(tidyverse))
like image 169
Albert Simmons Avatar answered Oct 17 '22 19:10

Albert Simmons


An alternative to suppressPackageStartupMessages is to set options(tidyverse.quiet = TRUE), which you can include in your .Rprofile.

Source: https://www.tidyverse.org/articles/2017/11/tidyverse_1.2.0/

like image 24
Mirabilis Avatar answered Oct 17 '22 19:10

Mirabilis