Collaborative and Reproducible Data Science in R
Cornell University, Spring 2021
All class activities are online.
Lectures: Mondays and Wednesdays 2:45pm - 4:00pm (Feb 8 - Apr 16, 2021)
Optional lab sessions: Fridays 12:25-2:20pm
Office hours: Nina: by appointment; Nicolas: Tuesday 2:30-3:30 or by appointment
Grading: S/U (2 credits / 3 credits with lab)
As datasets grow larger and more complex across all areas of science, computational skills are increasingly in high demand. This course introduces a series of practical tools that enable researchers to spend less time wrestling with software or repeating error-prone manual data processing and more time getting research done in efficient and transparent ways that facilitate collaboration and reproducibility. We will work in R/RStudio, primarily with the tidyverse packages and with Git and GitHub integration. Topics covered include 1) tidy data formatting, 2) rearrangement, filtering, exploration, and visualization of complex datasets, 3) basic programming for building and automating custom tools, 4) tracking the history of file changes (version control) with Git and GitHub, 5) strategies for effective collaboration on data processing pipelines, and 6) using R Markdown to combine text, equations, code, tables, and figures into reports, websites, and presentations. The course emphasizes practical skill development and will be structured around hands-on (the keyboard) learning.
By the end of this course, students will be able to:
A basic working knowledge of R will be helpful, but no prior experience with the tidyverse packages or with Git, GitHub, or R Markdown is assumed. If you have never worked in R before, we recommend working through one or more of the following tutorials before the course:
The two weekly lectures will introduce new concepts and provide opportunities to practice through hands-on exercises. To participate effectively, you must have completed the assigned readings prior to class. Each Wednesday, we will assign a problem set that applies the concepts covered in class in a new context to reinforce your learning. The problem sets are due the following Wednesday at 10pm. We offer an optional Friday afternoon lab session for more opportunities to practice in groups and with TA support.
It takes practice to acquire and internalize data science skills, and what you get out of this course will be proportional to the effort you put in. Practice as much as you can. To pass, students are expected to attend all lectures (and lab sessions if enrolled), participate actively during class, and submit at least 7 of the 9 problem sets with demonstrated effort to complete all questions. If you are unable to make a lecture or can not meet a problem set deadline, please email the instructor beforehand.
All assigned readings are freely available online and will be linked to from the course website. We will draw from a variety of sources, primarily Grolemund and Wickham’s R For Data Science and the STAT545 course developed by Jenny Bryan.
All students will need to bring a laptop to each session. Students who do not have their own laptop can arrange to borrow one from the Mann Library.
Please follow the instructions here to install the software we will need prior to the first class.
We are dedicated to providing a welcoming and supportive environment for everyone, regardless of background, identity and prior experience level. Everyone in this course will be coming from a different place with different experiences and expectations. We will not tolerate any form of language or behavior used to exclude, intimidate, or cause discomfort. This applies to all course participants (instructor, students, guests). In order to foster a positive and professional learning environment, we encourage the following kinds of behaviors:
In compliance with the Cornell University policy and equal access laws, we are available to discuss appropriate academic accommodations that may be required for student with disabilities. Requests for academic accommodations are to be made during the first two weeks of the course, except for unusual circumstances, so arrangements can be made. Students are encouraged to register with Student Disability Services to verify their eligibility for appropriate accommodations.
Subject to adjustment
|Class#||Day||Date||Topic||Assignment due dates|
|1||Mon||2/8||Intro to the course and R/RStudio|
|2||Wed||2/10||Markdown and GitHub|
|3||Mon||2/15||The Git workflow (version control)|
|4||Wed||2/17||Collaborating with GitHub Part 1||Assignment 1|
|5||Mon||2/22||Collaborating with GitHub Part 2|
|6||Wed||2/24||Plotting with ggplot part 1||Assignment 2|
|7||Mon||3/1||Data wrangling part 1 (dplyr::filter, mutate, select, arrange)|
|8||Wed||3/3||Data wrangling part 2 (dplyr::summarize, group_by)||Assignment 3|
|9||Mon||3/8||Plotting with ggplot part 2 + good coding practices|
|Wed||3/10||NO CLASS - Cornell Wellness Break|
|Fri||3/12||Lab 5||Assignment 4|
|11||Wed||3/17||Data import, export, and conversion between data types||Assignment 5|
|12||Mon||3/22||Good coding practices, debugging strategies, and getting help|
|13||Wed||3/24||Relational data||Assignment 6|
|14||Mon||3/29||Iteration (for loops) and conditional execution part 1|
|15||Wed||3/31||Iteration (for loops) and conditional execution part 2||Assignment 7|
|17||Wed||4/7||Factors in R||Assignment 8|
|18||Mon||4/12||Wrapping up and resources for learning more|
|19||Wed||4/14||Student presentations, wrapping up and looking ahead||Assignment 9|
|Fri||4/16||OPTIONAL: Lab 10 - Bring your own project|