This course introduces students to the fundamental practices of programming with R in the context of economic research. The course briefly covers basic theoretical concepts and teaches basic skills in how to make use of the high-level programming language and statistical computing environment R. Examples and exercises are focused on data handling and data analysis tasks. The overall aim is to give students a solid overview of basic programming in R, and how they can potentially make use of R during their studies and research in economics.
Download ZIP file with the necessary course data and files.
- Why R? Why programming?
- The tools: R, RStudio/Posit.
- First steps in R: R as a calculator, variables.
- Basic programming concepts in R.
- R objects and data structures.
- R functions for basic statistics.
- Loading/importing data.
- Visualizing data with R/ggplot.
- Basic data analysis with R/dplyr.
Time | Content |
---|---|
09:15 - 10:00 | Introduction, Background, Tools |
10:00 - 10:15 | Break, support with installations |
10:15 - 11:00 | First steps with R |
11:00 - 11:15 | Break, Q&A |
11:15 - 12:00 | Exercises |
12:00 - 13:30 | Lunch break |
13:30 - 14:15 | Working with data |
14:15 - 14:30 | Break, Q&A |
14:30 - 15:30 | Exercises |
There is no examination.
Jeremia Stalder and Erik-Jan Senn
Credits for a previous version of the course go to Prof. Ph.D. Ulrich Matter. Credits for a previous version of the slides go to Jonathan Chassot.