• Instructor: Kaufmann Marc; Office: 402, Nador 13; Email: [email protected] • Credits: 2 CEU (4 ECTS) • Term: Fall 2019-2020 • Course level: MA/MSc • Prerequisites: None • Course drop: Course can be dropped free of charge 24 hours after the first session. After this date drop is possible until the course is halfway over (late drop fee applies). No changes are allowed past that date.
The course serves as an introduction to the R programming language and software environment for data exploration, data munging, data analysis, and data visualization. As such it complements Data Analysis 1 and 2 which focus on the statistical methods, while this class focuses on how to program these methods in R.
• Produce meaningful descriptive statistics and informative graphs • Become familiar with the R ecosystem • Learn how to get help, how to debug, how to learn programming • Learn how to use R for the most common data tasks: loading, cleaning, transforming, summarizing, and visualizing data
Class materials are hosted on https://github.com/MarcKaufmann/R-Coding. Look there for an up-to-date syllabus.
• Participation (30%): helping yourself and helping others. This will be based on your contribution to the online class forum, as well as any other means you took to help yourself figure out how to solve issues you had. This can include getting help from classmates, or searching online forums and email lists. Part of the weekly assignment will be to document your use of any of these resources. • Assignments (77-78%): You will have weekly assignments, primarily consisting in completing R Markdown notebooks, and assessing those of your peers. Grading increases over time, with 1% for week one, increasing to 12% by the final week.
This sums to 107-108%, so you can lose 8% without it affecting your grade at all. There will be no final exam.
Minimum passing grade is 51%. Every increase in 7% leads to a higher grade: 51 to 57 yields a C; 58 to 64 yields a C+; 65 to 71 yields a B-; 72 to 78 yields a B; 79 to 85 yields a B+, 86 to 92 yields an A-; 93 to 100 yields an A.
Assignments: Since there are weekly assignments, I will not be able to grade them all. Instead, you will grade each others assignments. Thus, in week 2, you will grade two assignments of others from week 3, as well as your own. I will provide you with a (hopefully) clearcut rubric to do so. Half of your grade from assignments comes from grading others – half of it comes from the direct grade on your actual assignment.
Grading the assignments of others serves several purposes:
• There are too many assignments for me to grade • It is important that there are many assignments, so that you can get practice coding • By grading other people’s assignments, you will see different ways of solving things • By grading other people’s assignments, you will see how annoying some kinds of inconsistencies are when they are done by other people (and thus hopefully understand why these inconsistencies are annoying to others trying to read and understand your code) • Get in the habit of giving and receiving constructive feedback
Attendance: I will use https://www.youhere.org/ to track attendance from the second class onwards. I chose this app because it literally only checks whether you are or are not in class (through geolocation on your phone) at the time when you tap “Check me in”. It doesn’t store where you are (although it tells you how far away you are, but doesn’t store this information). Thus the only information I will have is:
- your first and last name as entered into the app (you can choose to enter a made up name)
- whether (and at what time) you tapped “Check me in” during class
- and whether the app determined that you were in class (“Yes”) or not (“No”)
If despite this you don’t want to or cannot install the app, let me know and I will check your attendance manually (via roll call).
• If you are fine with it, you can post on Discourse why you don’t want to do it or in an email to me. You do not have to justify your decision. • If there are technical problems for installing it, I would definitely like to know.
If you are fine installing the app:
• Install the app from https://www.youhere.org/ (follow the link to whichever marketplace you use) • Create a log in with a First and Last name. If you use another first and last name than the one on the roster, let me know so that I can track attendance properly. • Enroll in the class ‘r-coding’ • When you come to class, hit “Check me in”. If it does not work even though you are in class, let me know.
You will need your laptop with RStudio and R installed in order to participate in class.
Note: This is subject to substantial reording in the first 3 weeks, to allow both being in synch with other class (Data 1), as well as having a reasonably coherent flow. The set of topics will remain fairly stable.
- R ecosystem, basic syntax, R Markdown; how to get help; first plot
- ggplot2: data visualization
- Tidyverse: loading, showing, filtering, and selecting data
- Tidyverse: transforming and summarising data
- Sampling, simulating, bootstrapping
- Hypothesis testing
- Basic Regressions
- Functions, loops, and friends
- Debugging, testing, and documenting
- Basic Spatial Data
- Basic Time Series
- Recap and next steps
Marc Kaufmann teaches how to think with economic models, and how to use them to ask the right questions. He studied at Cambridge, Université Libre de Bruxelles, Berkeley, and Harvard. He studies the perceptions and beliefs people hold, how this affects their decisions and specifically their productivity.