From Spreadsheet to R

Two halves of a red apple, on the right you can see the skin, on the left you can see the inside of the apple.  Photo by Louis Hansel. Photo by Louis Hansel on Unsplash

Table of Contents


This course is intended for people who use spreadsheets for data manipulation and have never programmed, but would like to learn how to work with R. Therefore its starts from the beginning: why use R? and where to start?

We propose to work with R in an orderly and reproducible way. For this reason, we present a workflow that allows those who take this course to apply good programming practices, work collaboratively and present their work in a single document that includes the analysis and the results.

Whenever we can, we will mention how what we propose to solve with R can also be done with spreadsheets and the advantages and disadvantages of each approach.

In each section we include activities along with examples. We want these exercises to be realistic so that anyone can find similarities in their own data and can apply what they have learned to other situations

Intended public of this course

from Spreadsheet to R is intended for people who usespreadsheeets (Excel, Google sheets) for data manipulation and analysis but would like to learn how to use R. In particular we are thinking of:

  • Naomi: she is doing a PhD in genetics. Has been analyzing data with Excel for almost ten years. Is going to run 300 experiments in the next six months. Doesn’t want to have to do all the analyses by hand. And wants nicer charts for her thesis than she can produce in Excel.

  • Andrea: has been working for many years analyzing crops, yields and prices from data she receives in spreadsheets. They handles Excel very well and although they has to start every analysis from scratch and need to copy tables and plots to word for the reports they need to build, they has a lot of practice. They hear about R and they thinks it can be useful to automate they workflow, but at the same time it is a challenge to change the way they has always been working.

  • Rodrigo: works with data in Google Sheets, because he edit the files with other people. Is not as experienced and often makes mistakes that force him to start the analysis over again. At the same time he is afraid of losing the original data and ends up download and saving into disck many versions of the same file. He wants to learn to program but does not know whether to start using R or Python and whether he will be able to solve the problems he has with Google Sheets with either of these tools.

Check out personas to read more about them.


This is a 3-hour workshop with intervals (ideally away from any screen) of approximately 5 minutes for every 50 minutes of content.

Sample schedule

Duration (min) Activity
-5 Time to connect and make sure your audio and video connection is good (if you don’t have a camera it doesn’t matter, but if you do, it helps)
55 Introduction, reports, workflows
5 Break
55 Reading and Plotting
5 Break
30 Data manipulation
20 Reporting your work
10 Q&A, feedback and goodbye

Chapter 1 - Introductions and reports

  • Why R?
  • How are we going to work?
  • RMarkdown: Markdown text, R Code

Chapter 2 - Reading data

  • About palmerpenguins
  • Reading csv files
  • Reading xls file

Chapter 3 - Plotting Data

  • First layer: the area of the graphic
  • Second layer: geometries
  • Adding geometries
  • Let’s talk about the look of the plot

Chapter 4 - Data manipulation

  • Creating summary tables
  • Formatig the table
  • Creating new variables
  • Filtering data

Chapter 5 Reporting your work

  • Code control
  • Automatisation

Course materials

This course is part of the Research Software Engineering with R workshops series.

Do you want to re-use any of our contents? Please, be our guest!

Our materials are available for free under this license. You can reuse or edit any material that appears here, the only thing we ask in return is that when you reuse our materials you include a reference to this website.