Next: Installing R libraries locally
Up: R, S, and Splus
Previous: If/else syntax issues
The comprehensive R archive (CRAN)
has a bunch of very useful libraries. You can install a library from
within R using the install.packages() function. Among the
useful libraries I use are:
- maps: allows you to make maps of the world, the US, and smaller areas
- mapproj: allows you to do cartographic projections
- fields: lots of useful functions for spatial data, including kriging
and thin-plate splines
- nlme: linear and non-linear mixed effects models
- mgcv: provides a gam() function that allows you to do multivariate
non-parametric regression (i.e., non-additive modelling) using multiple
penalty optimization - this is a much more flexible model that the
gam() in Splus that does additive modelling
- ts: time series stuff
If your favorite Splus command is not available in R, it's likely
that the command or an equivalent version of it is available in an
R library that hasn't been loaded. A little rooting around at CRAN
will usually do the trick.
To load a library automatically when you begin your R session, include
the line
library(lib_name)
in your .Rprofile file.
Next: Installing R libraries locally
Up: R, S, and Splus
Previous: If/else syntax issues
Chris Paciorek
2006-04-02