6

Considering I have no programming background, Is there a resource out there that's the de-facto standard for describing best practices, design methodologies, and other helpful information on R programming? What about that resource makes it special?

Matthieu
  • 4,599

6 Answers6

8

I don't know if there is a book for a non-programmer in R or S but you can certainly start with the native R project site:

http://cran.r-project.org/

Starting with the Manuals section:

http://cran.r-project.org/manuals.html

Karlson
  • 815
2

From a design perspective I would definitely recommend Programming with data by John Chambers. He is the designer of the S language, of which R is the open source implementation. Another more conceptual book seems to be The Art of R Programming: A Tour of Statistical Software Design. There are number of statistics books which use R (Modern Applied statistics with S (and R), Introductory statistics with R), but these are already more aimed at the statistics, while you are probably more looking for a programming and not a stats book.

2

First of all, it is important to understand that R can be used for different purposes, each of which would have a particular book dedicated to it with some specific examples and applications.

The one I would definitely recommend for somebody who wants to understand R as a programming language is Software for Data Analysis: Programming with R. This book explains how the languages works in details. However, you will have few "concrete examples" of application. However, it is this book that made me feel completely fluent in R.

Then, I would suggest reading Data Manipulation with R which will explain you the different data structures which are quite different from one another and can be a pain during development if you haven't understood properly how they work.

Then you can find the book you want for the concretes examples on your field.

SRKX
  • 1,939
  • 1
  • 15
  • 24
2

I find Matloff's R for programmers a pretty good read (despite the title, it's perfectly suitable for non-programmers, such as myself and covers more or less everything, including the S4 class types), especially in conjunction with The R Inferno by Patrick Burns (teaches you about "gotcha's" in R). Both are freely available resources.

1

To directly answer your question: No, but see the main project website and official R manuals.

To indirectly answer your question: R is a pain in the butt to learn, because I've found that there are fifty ways to accomplish any single task, and that's pretty confusing for the new user. I'm going through this right now and I'm finding it as difficult as anyone.

The technique I found most useful was to learn the very basics of R by going through the first chapter or two of any R tutorial to get the language syntax, and then to go through homework problems from an R course. This way, instead of reading through the fifteen ways to sort a data frame, you can learn one way, try it out in the homework, and if it works, great, that's how you do it. If not, keep searching until you find a technique that does work.

eykanal
  • 1,684
0

I think the biggest challenge for me when I was learning R (and still learning) is the vast amount of information available for R (information overload really). I would suggest you purchase a book and use that as your defacto standard until you have a solid footing in R and handling data in R. There is literally a ton of information and help for using R. That is a huge benefit, but also can be a drawback. Especially if every example you come across by searching these forums or The Google uses different packages. The authors of most R books tend to be consistent and use the base R packages, or their favorite packages available form cran. The key to learning is consistency.

Although the references below are not specific to "programming" in R, and not "canonical" they are a great resource nonetheless and I will add them to supplement my answer.

derelict
  • 101