Welcome to R Café

Duration

3 weeks of study + 1 week of extra content (if any) and closing remarks

Structure

  • 3-hour face-to-face sessions per day, 1 day per week
  • Take home exercises given between face-to-face sessions

R Café helpful shortcuts

Agenda

  1. Getting started with R and Git (day 1)
    • Part 1: Setup (45’) - Tuyen & QA
      • What is R Café & Agenda (5’)
      • Brief introduction to Git, GitHub, and GitHub Desktop
        • Goal: Publish your own branch on R Café’s GitHub repository
      • Rstudio (20’)
        • Goal: Create RStudio project
        • Goal: Everyone create and push their first commit onto their own branch
      • Navigate GitHub
    • Part 2: Foundations of R (60’) - QA
      • Variables & Functions & Packages (with outline)
      • Exercises
        • Goal: Create a function and push to GitHub
        • Goal: Create issues and comment on each other’s issues on GitHub
    • Break (15’)
    • Part 3: Data manipulation in R (45’) - QA
      • Data management
      • Take-home exercises setup
  2. R programming with tidyverse (day 2)
    • Into the tidyverse
      • What is tidyverse?
      • Why should we use it?
      • How do we use it?
      • Piping with %>%
    • Exercise
    • Vectorise R functions
      • Vectors and vectorisation
      • Vectorisation with map()
      • tidyverse style vs. base R style
    • ggplot2 for data visualisation
      • Grammar of graphics
    • Exercise
  3. Quarto & Markdown (and related) (day 3)

Take-home exercises

  1. Initial Data Analysis - IDA (with skimr)
    • Generate questions around your data
    • Customize your summary table output
    • Simple visualization data, e.g. histogram
    • Calculate statistics, e.g. correlation, collinearity
  2. Data transformation
    • Data cleaning and filtering
    • Data transformation
    • Factor your data (with forcats)
    • Data visualization (with ggplot2)
  3. Analysis with gtsummary
    • Demographic summary
    • Statistical tests, e.g. t-test, chi-sq, fisher-exact, OR, etc.
  4. Generate report with Quarto
    • Citation (inline footnote and reference)