Jeff Lewis is Professor of Political Science at the University of California, Los Angeles, where his research focusses on political methodology, elections, and legislative politics. His work has appeared in leading political methodology journals and in 2003 he was awarded the Warren Miller Prize for best article published in Political Analysis. He served as the President of the Political Methodology Society from 2015-2017 and as Department Chair of the UCLA Political Science Department from 2011-2017. He regularly teaches courses on political methodology, statistics, and data analysis.

Course content: This course prepares students to write professional R code of the sort that is demanded when writing software that will be shared with others and that is best practice for all R users. By becoming a more professional programmer, you will code more efficiently. By learning contemporary tools of project management, you will be able to more quickly develop projects that are completely transparent and reproducible. And, by learning, how to harness the power of cloud computing, parallel processing, relational databases, and C++ from inside R, you will be able to analyze large data sets with computationally intensive methods more quickly and efficiently.

Course objectives:
• Improved R programming skills
• Knowledge of current best practice in R coding and project management.
• Familiarity with the latest R programming tools that increase coding and computational efficiency.
• Experience writing R packages and thinking about writing code that others will use.
• Exposure to how to use R in the cloud to analyze large data sets and increase computational performance through parallelization.

Students will be able to:
• Write more powerful, beautiful, and professional R code.
• Build and manage projects with GIT and Rstudio.
• Write R packages
• Harness the power of compiled languages (C++), relational databases, and cloud computing from inside R.

Core Reading:
Hadley Wickham. Advanced R. Boca Raton, FL: CRC Press, 2014.

Background knowledge required:
OLS = e
Maximum Likelihood = e

Computer Background
R = m/s
HTML = e

e = elementary, m = moderate, s = strong

More information will be available shortly.


Each day includes a homework assignment that puts the day’s lessons to work. Students are encouraged to come to the class with an R project that they would like to improve. Wherever possible, homework will involve applying what we have learned to students’ own projects. Generic problems are also provided for cases in which a given homework topic is not amenable to a student’s project.