Coding in R - Basics
Date: 17. September 2025
Speaker: Luke Günther, Project S, SFB 1252
Duration: 14:00 - 15:30
Overview
Introduction to R programming for research applications. This foundational workshop covers the R environment, basic programming concepts, data handling, and best practices for reproducible code.
Learning Objectives
- Set up and navigate the R programming environment
- Understand basic R data structures and operations
- Import and export data in various formats
- Use essential R packages for research
- Write clean, reproducible R code
- Debug common R programming errors
Topics Covered
- R and RStudio installation and setup
- Basic syntax, variables, and data types
- Vectors, lists, data frames, and matrices
- Data import/export (CSV, Excel, databases)
- Essential packages: tidyverse, readr, readxl
- Basic data manipulation and cleaning
- Writing functions and scripts
- Code organization and documentation
- Debugging strategies
Prerequisites
No prior programming experience required. Participants should have R and RStudio installed on their laptops.
Materials
Materials will be provided during the workshop, including:
- Installation guide
- Hands-on exercises
- Sample datasets
- Reference materials
Setup Instructions
Before the workshop, please:
- Install R from https://cran.r-project.org/
- Install RStudio Desktop from https://posit.co/downloads/
- Test that both programs open successfully
Additional Resources
- R for Data Science - Comprehensive online book
- RStudio Cheat Sheets - Quick reference guides
- Swirl - Interactive R programming lessons
- R Documentation - Function reference
Follow-up
This workshop prepares participants for the advanced "Computational Reproducibility Session using R" workshop later in the semester.