Packages are the fundamental way to document, share, and distribute R code and data. Our goal is to write our own packages, and our fair warning is that this chapter is particularly complex because of the many software tools that are employed during R package development.
In this chapter, we make sure of four packages. The devtools package (Wickham and Chang, 2016) provides functions to help set up, document, and manage the development of an R package. The roxygen2 package (Wickham, Danenberg, and Eugster, 2015) greatly ...