An Introduction to R (Network Theory Limited)
This book by William N. Venables, et al., covers many general topics, including statistics, graphics, and programming. You can download the free PDF book; or, better yet, buy the printed copy because the profits are donated to the R project.
R in a Nutshell (OReilly)
Joseph Adlers book is the tutorial and reference youll keep by your side. It covers many topics, from introductory material to advanced techniques.
Using R for Introductory Statistics (Chapman & Hall/CRC)
A good choice for learning R and statistics together by John Verzani. The book teaches statistical concepts together with the skills needed to apply them using R.
The R community has also produced many tutorials and introductions, especially in specialized topics. Most of this material is available on the Web, so I suggest searching there when you have a specific need (as in ).
The R project website keeps an extensive bibliography of books related to R, both for beginning and advanced users.
Downloading Additional Packages
The R project has over 2,000 packages that you can download to augment the standard distribution with additional capabilities. You might see such packages mentioned in the See Also section of a recipe, or you might discover one while searching the Web.
Most packages are available through the Comprehensive R Archive Network (CRAN) at http://cran.r-project.org. From the CRAN home page, click on Packages to see the name and a brief description of every available package. Click on a package name to see more information, including the package documentation.
Downloading and installing a package is simple via the install.packages
function. You would install the zoo
package this way, for example:
>
install.packages("zoo")
When R prompts you for a mirror site, select one near you. R will download both the package and any packages on which it depends, then install them onto your machine.
On Linux or Unix, I suggest having the systems administrator install packages into the system-wide directories, making them available to all users. If that is not possible, install the packages into your private directories.
Software and Platform Notes
The base distribution of R has frequent, planned releases, but the language definition and core implementation are stable. The recipes in this book should work with any recent release of the base distribution.
One recipe has platform-specific considerations (). As far as I know, all other recipes will work on all three major platforms for R: Windows, OS X, and Linux/Unix.
Conventions Used in This Book
The following typographical conventions are used in this book:
Italic
Indicates new terms, URLs, email addresses, filenames, and file extensions.
Constant width
Used for program listings, as well as within paragraphs to refer to program elements such as variable or function names, databases, data types, environment variables, statements, and keywords.
Constant width bold
Shows commands or other text that should be typed literally by the user.
Constant width italic
Shows text that should be replaced with user-supplied values or by values determined by context.
Tip
This icon signifies a tip, suggestion, or general note.
Caution
This icon indicates a warning or caution.
Using Code Examples
This book is here to help you get your job done. In general, you may use the code in this book in your programs and documentation. You do not need to contact us for permission unless youre reproducing a significant portion of the code. For example, writing a program that uses several chunks of code from this book does not require permission. Selling or distributing a CD-ROM of examples from OReilly books does require permission. Answering a question by citing this book and quoting example code does not require permission. Incorporating a significant amount of example code from this book into your products documentation does require permission.
We appreciate, but do not require, attribution. An attribution usually includes the title, author, publisher, and ISBN. For example: 25 Recipes for Getting Started with R by Paul Teetor (OReilly). Copyright 2011 Paul Teetor, 978-1-449-30323-5.
If you feel your use of code examples falls outside fair use or the permission given above, feel free to contact us at .
Safari Books Online
Note
Safari Books Online is an on-demand digital library that lets you easily search over 7,500 technology and creative reference books and videos to find the answers you need quickly.
With a subscription, you can read any page and watch any video from our library online. Read books on your cell phone and mobile devices. Access new titles before they are available for print, and get exclusive access to manuscripts in development and post feedback for the authors. Copy and paste code samples, organize your favorites, download chapters, bookmark key sections, create notes, print out pages, and benefit from tons of other time-saving features.
OReilly Media has uploaded this book to the Safari Books Online service. To have full digital access to this book and others on similar topics from OReilly and other publishers, sign up for free at http://my.safaribooksonline.com.