==================================================
Canadian Bioinformatics Workshops Series
Toronto, June 6, 2016
Introduction to R
Faculty: Boris Steipe boris.steipe@utoronto.ca
Module 1: The R Environment
==================================================
Let’s begin:
- Place a pink PostIt on your laptop screen so we know you are working on these instructions.
- Open this page in a browser on your computer.
- You should have R installed. If you don’t, install R now.
- You should have RStudio installed. If you don’t, install RStudio now.
- Replace the pink PostIt with a green one so we know you are done with this checkpoint.
Environment and user interface
Set up your workspace
Most of the workshop materials will be bundled in RStudio projects that you download on your computer. Let’s spend a moment to figure out where to put the project files, to keep things organized. We’ll discuss
- organizing your hard-drive;
- organizing project directories.
Supporting slides are here in case you need them.
Install the first project
- open RStudio
- Select File → NewProject…
- Click on Version Control
- Click on Git
- Enter
https://github.com/hyginn/R_Intro-Environment
as the Repository URL. - Click on Browse… to find your training directory…
- (The project-directory name should autofill to
R_Intro-Environment
) - Click Create Project; the project files should be downloaded and the console should prompt you to type
init()
to begin. - Type
init()
into the console pane. - Place a green PostIt if this has worked for you; place a pink PostIt if you run into issues or have questions.
From here onward, we will work with the scripts contained in the project files!
**Before we move on: let’s list our progress!
First steps with R: expressions, functions, data …
Install the second (main) project of the day:
- In RStudio Select File → NewProject…
- Click on Version Control
- Click on Git
- Enter
https://github.com/hyginn/R-Intro
as the Repository URL. - Click on Browse… to find your training directory…
- (The project-directory name should autofill to
R-Intro
) - Click Create Project; the project files should be downloaded and the console should prompt you to type
init()
to begin. - Type
init()
into the console pane. - Place a green PostIt if this has worked for you; place a pink PostIt if you run into issues or have questions.
Continue with the scripts and resources contained in the project files!
**Before we break up: let’s list our progress!
Useful Resources
- The R help mailing list: https://stat.ethz.ch/mailman/listinfo/r-help
- Rseek: the specialized search engine for R topics: http://rseek.org/
- R questions on stackoverflow: http://stackoverflow.com/questions/tagged/r
- The Comprehensive R Archive Network CRAN: http://cran.r-project.org/
- The CRAN task-view collection: http://cran.r-project.org/web/views/
- Bioconductor task views: http://www.bioconductor.org/packages/release/BiocViews.html