R Development Core Team, 2004. — 96 p. — ISBN: 3900051127
This introduction to R is derived from an original set of notes describing the S and S-Plus environments written by Bill Venables and David M. Smith (Insightful Corporation). We have made a number of small changes to reflect differences between the R and S programs, and expanded some of the material.
We would like to extend warm thanks to Bill Venables (and David Smith) for granting permission to distribute this modified version of the notes in this way, and for being a supporter of R from way back.
R and statistics
Using R interactively
R commands, case sensitivity, etc
Data permanency and removing objects
Vector arithmetic
Generating regular sequences
Missing values
Index vectors; selecting and modifying subsets of a data set
Other types of objects
Intrinsic attributes: mode and length
The class of an object
The function tapply() and ragged arrays
Ordered factors
Array indexing. Subsections of an array
Index arrays
The outer product of two arrays
Matrix facilities
Eigenvalues and eigenvectors
Least squares fitting and the QR decomposition
Frequency tables from factors
Constructing and modifying lists
attach() and detach()
Attaching arbitrary lists
Managing the search path
The read.table() function
Loading data from other R packages
Editing data
R as a set of statistical tables
Examining the distribution of a set of data
One- and two-sample tests
Repetitive execution: for loops, repeat and while
Simple examples
Named arguments and defaults
Efficiency factors in block designs
Recursive numerical integration
Scope
Classes, generic functions and object orientation
Defining statistical models; formulae
Contrasts
Generic functions for extracting model information
Updating fitted models
Families
The glm() function
Least squares
Maximum likelihood
Some non-standard models
The plot() function
Display graphics
Arguments to high-level plotting functions
Low-level plotting commands
Interacting with graphics
Permanent changes: The par() function
Graphics parameters list
Axes and tick marks
Figure margins
Multiple figure environment
Device drivers
Multiple graphics devices
Dynamic graphics
Namespaces
A sample session
Invoking R from the command line
Invoking R under Mac OS X
Command-line editor summary
Function and variable index