While most R packages on CRAN are designed to be used by an R user directly, a few packages are designed to be used by other package developers. (And some packages are so useful that they're regularly used by both camps.) When a package author publishes a package to CRAN, she must list those packages that provide functions her package uses (this is the Depends: field in the DESCRIPTION file). The number of times a package is listed as a dependency is a measure of how often it's relied upon by package authors.
Dirk Eddelbuettel recently analyzed the packages on CRAN according to the number of times they were listed as a dependency by other packages, and the top 10 packages were:
- mvtnorm: Multivariate Normal and t Distributions
- coda: Output analysis and diagnostics for MCMC
- Rcpp: Seamless R and C++ Integration
- sp: Classes and methods for spatial data
- rgl: 3D visualization device system (OpenGL)
- ggplot2: An implementation of the Grammar of Graphics
- XML: Tools for parsing and generating XML within R and S-Plus
- rJava: Low-level R to Java interface
- Hmisc: Harrell Miscellaneous
- zoo: S3 Infrastructure for Regular and Irregular Time Series (Z's ordered observations)
These are the top 10 “critical packages” on CRAN, in the sense that if they disappeared from CRAN or stopped working, they'd make many other packages that depend on them break as well. I didn't include in this list any of the “recommended” R packages, because they're included in R's standard distribution and generally considered to be “part of R. Nonetheless, the packages MASS, lattice, survival, Matrix, nlme and boot all appear in the top 10 of the most frequently-cited package dependencies in Dirk's chart below, so it makes sense that they're made available to all R users.
Thinking outside the box: Counting CRAN Package Depends, Imports and LinkingTo