An Introduction to R and RStudio

What is R?

R is a programming language and software environment for statistical computing and graphing. It is an implementation of the S language, was created at the University of Auckland in New Zealand, and is now developed by the R Development Core Team. R is part of the GNU project with its source code freely available under the GNU General Public Licence, and precompiled binary versionsfn2 available for various operating systems. R uses a command line interface, yet there are many groups developing and maintaining graphical user interfaces (Gui’s) for use with R (we'll discuss this in depth later).

R provides a wide variety of statistical techniques; linear and non-linear modelling, classical statistical tests, time-series analysis, classification, clustering, and more. It also features powerful graphing techniques and is high extensible through installable packages. R provides a powerful means for research in statistical methodology and bioinformatics.

The R environment

R is an integrated suite of software facilities for data manipulation, calculation and graphical display. It includes:

  • Effective data handling and storage facility
  • A suite of operators for calculations on arrays/matrices
  • A large, coherent, integrated collection of intermediate tools for data analysis
  • Graphical facilities for data analysis and display either on screen or hardcopy
  • A well-developed, simple and effective programming language which includes conditionals, loops, user-defined recursive functions and input output facilities

Why use R?

  1. It’s free. R is open source software, and as such is free to everyone. There is a very active community of developers that constantly work on add functionality and advancing R.

  2. It runs on a variety of platforms, including Windows, Linux and Mac OS X. So whatever your flavour you’ll be able to run it.

  3. It provides an unparalleled platform for programming new statistical methods in a fairly easy and straight forward manner. Due to the package nature of R it’s fairly easy to develop new tools quickly.

  4. It contains advanced statistical routines not yet available in other software.

  5. It has state of the art graphics capabilities. With R you have complete control over plotting/graphing options and are able to output publication quality figures with ease.

  6. It’s funfn3

Where can I get R?

R can be obtained from the r-project website. For a much more detailed explanation of how to get R and install it please read on.


fn2 Don’t worry if this makes no sense, it’s just fancy language for ‘click to install’.

fn3 Your mileage may vary, but hopefully it will become less of a chore and more enjoyable as you learn.