# Schedule

Key resources: *R for Data Science (2e)* by Hadley Wickham, Mine Çetinkaya-Rundel, and Garrett Grolemund, *Preceptor’s Primer for Bayesian Data Science* by David Kane, *Analyzing US Census Data: Methods, Maps, and Models in R* by Kyle Walker, along with their their associated tutorials. Homework should be completed before the class meeting for which it is assigned.

See the home pages for the **r4ds.tutorials**, **primer.tutorials**, and **tidycensus.tutorials** for installation instructions.

**Always reinstall the relevant package before starting a new tutorial.** Example for **primer.tutorials**:

```
remove.packages("primer.tutorials")
remotes::install_github("PPBDS/primer.tutorials")
```

We are always fixing mistakes. You want to use the latest version.

Completed tutorials are submitted via this Google form. If you do not complete the tutorials on time, you will be removed from the class. Send in your tutorial answers saved in *html* format. Please try to ensure that the name of the file is the default name, like `getting-started_answers.html`

. Avoid using the name which will be assigned to the file if you download the same answers twice (or more), stuff like `getting-started_answers (2).html`

. You can just change the name of the file by hand if this happens.

# Registration

To register for the class and reserve your spot, please read Getting Started and follow all the associated instructions. Complete the “Getting Started with Tutorials” tutorial from the **tutorial.helpers** package. Submit your answers, as an html file, via this Google form.

# Week 1: Data

Looking at the data is the first step in data science. Note that Monday’s homework must be completed before Monday’s class. I ensure this by only sending the Zoom link for class to students who submitted the homework.

## Monday

Read the Introduction from

*R for Data Science (2e)*.From the

**r4ds.tutorials**package, complete the “Introduction” tutorial. Submit your answers via the usual Google form.

## Thursday

Read Chapters 1 – 4 from

*R for Data Science (2e)*.From the

**r4ds.tutorials**package, complete four tutorials: “Data Visualization,” “RStudio and Code,” “Data Transformation,” and “RStudio and Github.” Submit your answers via the usual Google form.

**Reminder**: All work must be completed before class. Failure to submit your tutorial answers will result in you being removed from the course. It is not fair to your fellow students, with whom you will be working in small groups, for you to not be prepared for class.

# Week 2: Models

Now that we know how to visualize data that is already clean, we need to learn how to clean up messy data.

## Monday

- Read Chapters 5, 6, 7, and 8 from
*R for Data Science (2e)*, and from the**r4ds.tutorials**package, complete the tutorials associated with the readings: “Data Tidying,” “Terminal,” “Data Import,” and “Getting Help.”

## Thursday

Read Chapters 9, 10 and 11 from

*R for Data Science (2e)*, and from the**r4ds.tutorials**package, complete the tutorials associated with the readings: “Layers,” “Exploratory Data Analysis,” and “Communication.”Read chapters 1 and 2 from from

*Analyzing US Census Data: Methods, Maps, and Models in R*by Kyle Walker. The U.S. Census is a great source of data for your projects.From the

**tidycensus.tutorials**package, complete the “An introduction to tidycensus” tutorial.

# Week 3: Inference

## Monday

Read chapters 12, 13, 28 and 29 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Logical vectors,” “Numbers,” and “Quarto Websites” tutorials.Come to class with the url for at least one data source you will be using for your Data Project.

## Thursday

- Read chapters 14, 15 and 16 from
*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Strings,” “Regular expressions” and “Factors” tutorials.

# Week 4: Wisdom

The main focus on the 4th week is individual presentations of your Data Project. Do you love soccer or wine or NYC politics? The Data Project provides you with an opportunity to study that topic in depth. Your Data Project will be, for most of you, the first item in your professional portfolio, something so impressive that you will be eager to show it to graduate schools or potential employers.

## Monday

Read chapter 17 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Dates and times” tutorial.Complete the “Data Project” tutorial from the

**primer.tutorials**package. Be sure to reinstall the package before starting the tutorial.

## Wednesday

Read chapter 18 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Missing values” tutorial.Practice presentations and feedback. You must have your presentation ready to go!

## Thursday

- Data Project presentations. You must invite someone, and bcc your TF when you do so. The presentations are public.

# Week 5: Justice

## Monday

Read Chapter 1 Rubin Causal Model and Chapter 2 Probability.

From the

**primer.tutorials**package, complete “Rubin Causal Model” and “Probability” tutorials.Read chapter 19 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Joins” tutorial.

## Wednesday

Read Chapter 3: Sampling and, from the

**primer.tutorials**package, complete the “Sampling” tutorial.Read chapter 20 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Spreadsheets” tutorial.

## Thursday

Read Chapter 4: Models and, from the

**primer.tutorials**package, complete the “Models” tutorial.Read chapter 21 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Databases” tutorial.

# Week 6: Courage

## Monday

Read Cardinal Virtues.

Read Chapter 5: Two Parameters and, from the

**primer.tutorials**package, complete the “Two Parameters” tutorial.Read Chapter 6: Three Parameters: Causal and, from the

**primer.tutorials**package, complete the “Three Parameters: Causal” tutorial.

## Wednesday

Read Chapter 7: Mechanics and, from the

**primer.tutorials**package, complete the “Mechanics” tutorial.Read Chapter 8: Four Parameters: Categorical and, from the

**primer.tutorials**package, complete the “Four Parameters: Categorical” tutorial.

## Thursday

Read chapter 22 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Arrow” tutorial.Read chapter 23 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Hierarchical data” tutorial.

# Week 7: Temperance

## Monday

Read Chapter 9: Five Parameters and, from the

**primer.tutorials**package, complete the “Five Parameters” tutorial.Read Chapter 10: N Parameters and, from the

**primer.tutorials**package, complete the “N Parameters” tutorial.

## Wednesday

Read chapter 24 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Web scraping” tutorial.Read chapter 25 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Functions” tutorial.

## Thursday

Read chapter 26 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “Iteration” tutorial.Read chapter 27 from

*R for Data Science (2e)*and, from the**r4ds.tutorials**package, complete the “A field guide to base R” tutorial.

# Week 8: Projects

The last week will consist of projects that the students will make.

## Monday

From the

**primer.tutorials**package, complete the “Project” tutorial before class, or you will be removed the course. There are no extensions for this assignment.You must have a draft of your final project ready to go, including a Quarto website and your paragraph introduction.

## Wednesday

- Practice presentations and feedback. You must have your presentation ready to go!

## Thursday

- Final project presentations. You must invite someone, and bcc your TF when you do so.