[R] Using require() vs. library()

Nordlund, Dan (DSHS/RDA) NordlDJ at dshs.wa.gov
Wed Aug 17 18:40:47 CEST 2011


A recent post prompts me to ask this question.  Is there any reason to prefer using library() over require()?  I tend to use require() instead of library() to load packages, but I wonder if there are situations where it would be better to use library().  

Enquiring minds would like to know,

Dan

Daniel J. Nordlund
Washington State Department of Social and Health Services
Planning, Performance, and Accountability
Research and Data Analysis Division
Olympia, WA 98504-5204



More information about the R-help mailing list