Slide 1

Slide 1 text

🔗 bit.ly/dsbox-turing mine-cetinkaya-rundel [email protected] MINE ÇETINKAYA-RUNDEL DUKE UNIVERSITY + POSIT

Slide 2

Slide 2 text

🔗 bit.ly/dsbox-turing Three questions that keep me up at night… 1 What should my students learn? 2 How will my students learn best? 3 What tools will enhance my students’ learning?

Slide 3

Slide 3 text

🔗 bit.ly/dsbox-turing 1 What should my students learn? 2 How will my students learn best? 3 What tools will enhance my students’ learning? Three questions that keep me up at night… Content Pedagogy Infrastructure

Slide 4

Slide 4 text

🔗 bit.ly/dsbox-turing Infrastructure Pedagogy Content

Slide 5

Slide 5 text

🔗 bit.ly/dsbox-turing Infrastructure Pedagogy Content

Slide 6

Slide 6 text

🔗 bit.ly/dsbox-turing

Slide 7

Slide 7 text

🔗 bit.ly/dsbox-turing 🔗 datasciencebox.org 🔗 tidyverse/datascience-box

Slide 8

Slide 8 text

🔗 bit.ly/dsbox-turing AUDIENCE I have been teaching with R for a while, but I want to update my teaching materials I’m new to teaching with R and need to build up my course materials This teaching slide deck I came across on Twitter is pretty cool, but I have no idea what type of course it belongs in

Slide 9

Slide 9 text

🔗 bit.ly/dsbox-turing DOING DATA SCIENCE Program Import Tidy Transform Visualize Model Communicate Understand Wickham, H., Çetinkaya-Rundel, M., & Grolemund, G. (2023). R for Data Science, 2nd Edition.

Slide 10

Slide 10 text

🔗 bit.ly/dsbox-turing TEACHING DATA SCIENCE Communicate

Slide 11

Slide 11 text

🔗 bit.ly/dsbox-turing CONTENTS 🖥 🎥 48 slide decks + videos 🤼 10 application exercises 👩🔬 14 computing labs ✍ 10 homework assignments ✔ 2 take-home exams 📝 1 open-ended project 🤹 10 interactive tutorials website datasciencebox.org repository package dsbox

Slide 12

Slide 12 text

🔗 bit.ly/dsbox-turing DESIGN PRINCIPLES 🎉 cherish day one 👶 skip baby steps 🍰 start with cake 🌲 leverage the ecosystem 🥦 hide the veggies

Slide 13

Slide 13 text

DESIGN PRINCIPLES Which kitchen would you rather bake a cake?

Slide 14

Slide 14 text

DESIGN PRINCIPLES Which kitchen would you rather bake a cake?

Slide 15

Slide 15 text

DESIGN PRINCIPLES 🎉 Cherish day one ‣ Go to Posit Cloud ‣ Start the project titled UN Votes

Slide 16

Slide 16 text

DESIGN PRINCIPLES 🎉 Cherish day one ‣ Open the Quarto document called unvotes.qmd

Slide 17

Slide 17 text

DESIGN PRINCIPLES 🎉 Cherish day one ‣ Render the document and review the data visualization you just produced

Slide 18

Slide 18 text

DESIGN PRINCIPLES How do you prefer your cake recipes? Words only, or words & pictures?

Slide 19

Slide 19 text

DESIGN PRINCIPLES How do you prefer your cake recipes? Words only, or words & pictures?

Slide 20

Slide 20 text

DESIGN PRINCIPLES 🍰 Start with cake ‣ Open today’s demo project ‣ Render the document and discuss the results with your neighbor ‣ Then, change Turkey to a different country, and plot again

Slide 21

Slide 21 text

DESIGN PRINCIPLES 🍰 Start with cake With great examples, comes a great amount of code… but let’s focus on the task at hand… ‣ Open today’s demo project ‣ Knit the document and discuss the results with your neighbor ‣ Then, change Turkey to a different country, and plot again

Slide 22

Slide 22 text

DESIGN PRINCIPLES 🍰 Start with cake un_votes |> f i lter(country %in% c("United Kingdom", "United States", "Turkey")) |> inner_join(un_roll_calls, by = "rcid") |> inner_join(un_roll_call_issues, by = "rcid") |> group_by(country, year = year(date), issue) |> summarize( votes = n(), percent_yes = mean(vote == "yes") ) |> f i lter(votes > 5) |> # only use records where there are more than 5 votes ggplot(mapping = aes(x = year, y = percent_yes, color = country)) + geom_smooth(method = "loess", se = FALSE) + facet_wrap(~ issue) + labs( title = "Percentage of Yes votes in the UN General Assembly", subtitle = "1946 to 2015", y = "% Yes", x = "Year", color = "Country" )

Slide 23

Slide 23 text

DESIGN PRINCIPLES 🍰 Start with cake un_votes |> f i lter(country %in% c("United Kingdom", "United States", "Turkey")) |> inner_join(un_roll_calls, by = "rcid") |> inner_join(un_roll_call_issues, by = "rcid") |> group_by(country, year = year(date), issue) |> summarize( votes = n(), percent_yes = mean(vote == "yes") ) |> f i lter(votes > 5) |> # only use records where there are more than 5 votes ggplot(mapping = aes(x = year, y = percent_yes, color = country)) + geom_smooth(method = "loess", se = FALSE) + facet_wrap(~ issue) + labs( title = "Percentage of Yes votes in the UN General Assembly", subtitle = "1946 to 2015", y = "% Yes", x = "Year", color = "Country" )

Slide 24

Slide 24 text

DESIGN PRINCIPLES 🍰 Start with cake un_votes |> f i lter(country %in% c("United Kingdom", "United States", "Turkey")) |> inner_join(un_roll_calls, by = "rcid") |> inner_join(un_roll_call_issues, by = "rcid") |> group_by(country, year = year(date), issue) |> summarize( votes = n(), percent_yes = mean(vote == "yes") ) |> f i lter(votes > 5) |> # only use records where there are more than 5 votes ggplot(mapping = aes(x = year, y = percent_yes, color = country)) + geom_smooth(method = "loess", se = FALSE) + facet_wrap(~ issue) + labs( title = "Percentage of Yes votes in the UN General Assembly", subtitle = "1946 to 2015", y = "% Yes", x = "Year", color = "Country" )

Slide 25

Slide 25 text

DESIGN PRINCIPLES 🍰 Start with cake un_votes |> f i lter(country %in% c("United Kingdom", "United States", "France")) |> inner_join(un_roll_calls, by = "rcid") |> inner_join(un_roll_call_issues, by = "rcid") |> group_by(country, year = year(date), issue) |> summarize( votes = n(), percent_yes = mean(vote == "yes") ) |> f i lter(votes > 5) |> # only use records where there are more than 5 votes ggplot(mapping = aes(x = year, y = percent_yes, color = country)) + geom_smooth(method = "loess", se = FALSE) + facet_wrap(~ issue) + labs( title = "Percentage of Yes votes in the UN General Assembly", subtitle = "1946 to 2015", y = "% Yes", x = "Year", color = "Country" )

Slide 26

Slide 26 text

DESIGN PRINCIPLES 🍰 Start with cake

Slide 27

Slide 27 text

DESIGN PRINCIPLES Which motivates you more to learn how to cook: perfectly chopped onions or ratatouille?

Slide 28

Slide 28 text

DESIGN PRINCIPLES Which motivates you more to learn how to cook: perfectly chopped onions or ratatouille?

Slide 29

Slide 29 text

DESIGN PRINCIPLES 👶 Skip baby steps Re-insert

Slide 30

Slide 30 text

DESIGN PRINCIPLES Which is more likely to appeal to someone who has never tried broccoli?

Slide 31

Slide 31 text

DESIGN PRINCIPLES Which is more likely to appeal to someone who has never tried broccoli?

Slide 32

Slide 32 text

DESIGN PRINCIPLES 🥦 Hide the veggies ‣ Today we go from this to that ‣ And do so in a way that is easy to replicate for another state →

Slide 33

Slide 33 text

DESIGN PRINCIPLES Lesson: Web scraping essentials for turning a structured table into a data frame in R. 🥦 Hide the veggies

Slide 34

Slide 34 text

DESIGN PRINCIPLES Lesson: Web scraping essentials for turning a structured table into a data frame in R. Ex 1: Scrape the table off the web and save as a data frame. 🥦 Hide the veggies

Slide 35

Slide 35 text

DESIGN PRINCIPLES Lesson: Web scraping essentials for turning a structured table into a data frame in R. Ex 1: Scrape the table off the web and save as a data frame. Ex 2: What other information do we need represented as variables to make this figure? 🥦 Hide the veggies

Slide 36

Slide 36 text

DESIGN PRINCIPLES Lesson: Web scraping essentials for turning a structured table into a data frame in R. Ex 1: Scrape the table off the web and save as a data frame. Ex 2: What other information do we need represented as variables to make this figure? Lesson: “Just enough” regex 🥦 Hide the veggies

Slide 37

Slide 37 text

DESIGN PRINCIPLES If you are already taking a baking class, which will be easier to venture on to?

Slide 38

Slide 38 text

DESIGN PRINCIPLES If you are already taking a baking class, which will be easier to venture on to?

Slide 39

Slide 39 text

DESIGN PRINCIPLES 🌲 Leverage the ecosystem student-facing + or another browser/ server-based solution … instructor-facing 📦 ghclass + 📦 checklist + + 📦 learnr + 📦 gradethis 📦 learnrhash

Slide 40

Slide 40 text

🔗 bit.ly/dsbox-turing USAGE in full to jumpstart / overhaul your teaching in bits & pieces to supplement your teaching

Slide 41

Slide 41 text

🔗 bit.ly/dsbox-turing LICENSE

Slide 42

Slide 42 text

🔗 bit.ly/dsbox-turing CONTRIBUTIONS

Slide 43

Slide 43 text

🔗 bit.ly/dsbox-turing FUTURE more interactivity with webR update tooling to leverage Quarto fully what else? more frequent community engagement

Slide 44

Slide 44 text

mine-cetinkaya-rundel [email protected] MINE ÇETINKAYA-RUNDEL DUKE UNIVERSITY + POSIT 🗂 datasciencebox.org 📦 github.com/tidyverse/dsbox 🖥 bit.ly/dsbox-turing