Jeromy Anglim's Blog: Psychology and Statistics


Saturday, June 6, 2009

Learning R for Researchers in Psychology

R is a powerful open source environment for statistical computing. This post provides a selective list of resources for getting started with R including thoughts on books, online manuals, blogs, videos, user interfaces, and more. At the end of the post are some R resources specific to researchers in psychology. (UPDATED 4th May 2011)

Getting Started

  • Download and Install R

    • R runs on Windows (see this FAQ for Windows), Mac, and Linux
    • It can be downloaded for free from the official R website
  • Watch Videos on R:

  • Organise a user interface to R.

  • Read some free online documentation

  • Memorise important R commands

  • Stay up to date on R News:

    • Subscribe to the RSS feed of R-Bloggers: It syndicates many, if not most, of the R related posts in the blogosphere.
    • If alternatively you want to follow fewer posts, David Smith tends to post important R news and links to noteworthy blog posts by others.
    • R Journal, formerly called "R News", publishes R related articles.
  • Know how to find answers to your questions

    • Learn how to use built-in documentation (e.g., help, ?, apropos, help.search, etc.)
    • Google is still good (despite the many meanings of the letter "R"). I generally just use it
    • Rseek is an R specific search engine
  • Know where to ask questions to the R community:

    • R Tag on StackOverflow: A good option for anything related to programming in R.
    • Cross Validated: This is part of the Stack Exchange network. This is a good option if the question concerns statistical elements of R.
    • R Help Mailing List: Another option for asking R related questions with many R gurus in attendance.
    • With all these forums a good question will typically be answered within a day.
  • Learn about additional R packages

    • Base R often does most of what you want, but there are thousands of user contributed packages.
    • R Task Views organises the many R packages into various topics.
    • lattice, ggplot2, plyr, nlme are some general packages relevant to a lot of people.
  • Get some good books (free or paid):

    • The question of good books on R was asked on Stack Overflow. In particular, this answer lists several good free online options.
    • The R website lists many of the increasing number books on R that are being released.
    • Some of the books on R that I have enjoyed reading include the following:
      • Software for Data Analysis (2008): John Chambers: This gives a sense of the philosophy and style of programming in R. It is an intermediate to advanced text.
      • Data Manipulation with R: Phil Spector: This book is short, concise, and very clear. The examples are well chosen.
      • Data Analysis and Graphics Using R - An Example-Based Approach: John Maindonald and John Braun: This provides a good introduction to R. It also covers many techniques useful in psychology introducing several interesting techniques that are not necessarily part of the standard psychology statistics curriculum.
      • Books in the ;The Springer UseR Series tend be quite good.
      • But there are many more.
  • Engage with the R community

Additional Resources

The following are some additional R web resources that I have liked over the while.

Psychology Specific R Resources

3 comments:

  1. I would also point to the R Programming wikibook, which is a nice project of an open content textbook (still in development).

    ReplyDelete
  2. Here is the link http://en.wikibooks.org/wiki/R_Programming

    ReplyDelete
  3. If you're coming to R from SAS or SPSS, the early version of "R for SAS and SPSS Users" is free at http://r4stats.com. There's also a table there comparing SAS/SPSS add-ons to r packages that are roughly equivalent.

    If you're curious about how popular R is compared to most other stat packages, see:
    http://r4stats.com/popularity.

    Cheers,
    Bob Muenchen

    ReplyDelete