INSTRUCTOR MATERIALS FOR DSS

dss

 

UNOFFICIAL WEBSITE OF INSTRUCTOR MATERIALS FOR

 

DATA ANALYSIS FOR SOCIAL SCIENCE:

A FRIENDLY AND PRACTICAL INTRODUCTION

 

Elena Llaudet and Kosuke Imai

 

An ideal textbook for complete beginners teaches from scratch R, statistics, and the fundamentals of quantitative social science

 

Look Inside                     |      Purchase from Amazon              |      Provide Feedback
Request Exam Copy      |      Preview Instructor Resources     |      Request Instructor Resources

 

 

 

On this page, you will find some of the materials we make available to instructors using Data Analysis for Social Science (DSS for short). They include: (1) my syllabus, (2) my lecture slides, (3) the code and real-world datasets used in the exercises in the book, (4) the questions asked in the additional exercises we provide instructors using DSS, which can be used as in-class exercises or as take-home problem sets, and (5) links to the interactive graphs I have created to help readers of DSS develop an intuition about some of the trickier concepts in statistics.

Instructors who are using DSS as the main textbook in their course can request from Princeton University Press access to ALL the instructor resources, which include: (1) the files necessary to produce and change all the PDFs below, (2) the real-world datasets analyzed in the additional exercises, and (3) the solutions to given exercises. 

INSTRUCTOR MATERIALS

Course Syllabus. The course progresses through bite-sized exercises, which students have a chance to practice at least three times: once with the textbook, once with the in-class exercises, and once with the take-home weekly problem sets. All three–textbook, class, and problem sets–move in parallel, asking similar questions, but using different real-world datasets so that students get to see the same material in different contexts. Below you will find the resources associated with each chapter:

Although also provided below chapter-by-chapter, all the code and all the real-world datasets used in the exercises in the book are in a folder named DSS here. We recommend downloading this folder, unzipping it, and saving it directly on your Desktop, which is where the code used throughout the book assumes the DSS folder is located. (Datasets and code are also available in this GitHub repository.)

IMPORTANT NOTES:

  • There is a lot more material in DSS than what my lecture slides cover. My course skips some of the more advanced-level material in DSS because it is meant for undergraduate students with no prior knowledge of coding or statistics and only minimal knowledge of math. 
  • My lecture slides are meant to complement DSS, not be a substitute. They assume students come to class having done the readings and having followed along with the exercises in the book on their own computer. In class, we go over a different replication-style exercise (asking similar questions but analyzing different data) and my slides do not always repeat all the explanations and details given in the book.
  • Any errors found in the instructor resources are my own. If you find any, I would really appreciate it if you could let me know by sending me an email at ellaudet@gmail.com. Thank you!                                                        (The materials on this page were last updated on 11/02/2023.)

 

CHAPTER 1: INTRODUCTION
In chapter 1, we start from the very beginning by installing and familiarizing ourselves with the two programs we use―R and RStudio―and by laying the groundwork for forthcoming analyses. 

Code and Data Used in the Exercises in the Book:
Introduction.R (R script with the code) and STAR.csv (CSV file with the data)

Lectures Slides:
Lecture 1. Course Introduction
Lecture 2. Introduction to R and RStudio (Readings: 1-1.6 of DSS, including both)
Lecture 3. Observations and Variables (Readings: 1.7)
Lecture 4. Computing and Interpreting Means (Readings: 1.8-1.10)

Questions Asked in the Additional Exercises Provided to Instructors Using DSS:
Estimating the Bias in Self-Reported Turnout - Part I: Loading and Making Sense of Data
Estimating the Bias in Self-Reported Turnout - Part II: Computing and Interpreting Means
Effects of A Criminal Record in Labor Market - Part I: Loading and Making Sense of Data
Effects of A Criminal Record in Labor Market - Part II: Computing and Interpreting Means
Effects of Female Leaders in India - Part I: Loading and Making Sense of Data
Effects of Female Leaders in India - Part II: Computing and Interpreting Means
Effects of Social Pressure Message on Probability of Voting - Part I: Loading and Making Sense of Data, and Computing and Interpreting Means

Self-Guided Practice Exercises:  (**NEW**)
To Access Them Run the Code in This R Script in RStudio

CHAPTER 2: ESTIMATING CAUSAL EFFECTS WITH RANDOMIZED EXPERIMENTS
In chapter 2, we learn what causal effects are and how to estimate them using randomized experiments. We analyze data from Project STAR to answer: What is the effect of small classes on student performance?

Code and Data Used in the Exercises in the Book:
Experimental.R (R script with the code) and STAR.csv (CSV file with the data)

Lectures Slides:
Lecture 5. Causal Effects and Randomized Experiments (Readings: 2-2.4, Video: How to Run a Randomized Experiment)
Lecture 6. Does Social Pressure Affect Turnout? (Readings: 2.5-2.7)

Questions Asked in the Additional Exercises Provided to Instructors Using DSS:
Effects of A Criminal Record in Labor Market - Part III: Estimating an Average Causal Effect
Effects of Female Leaders in India - Part III: Estimating an Average Causal Effect
Effects of Social Pressure Message on Probability of Voting - Part II: Estimating an Average Causal Effect

Interactive Graphs:
Random Treatment Assignment Makes Treatment and Control Groups Comparable When the Sample Size is Large Enough

Self-Guided Practice Exercises:  (**NEW**)
To Access Them Run the Code in This R Script in RStudio

CHAPTER 3: INFERRING POPULATION CHARACTERISTICS VIA SURVEY RESEARCH

In chapter 3, we learn about surveys and how to visualize and summarize the distribution of single variables as well as the relationship between two variables. We analyze data on the 2016 British referendum to answer: Who Supported Brexit?

Code and Data Used in the Exercises in the Book:
Population.R (R script with the code) and BES.csv & UK_districts.csv (CSV files with the data)

Lecture Slides:
Lecture 7. Survey Research and Exploring One Variable at a Time (Readings: 3-3.4)
Lecture 8. Review
Lecture 9. Exploring the Relationship Between Two Variables (Readings: 3.5-3.7)

Questions Asked in the Additional Exercises Provided to Instructors Using DSS:
Estimating the Bias in Self-Reported Turnout - Part III: Subsetting Variables and Creating Histograms
Evidence of Data Fabrication
Effects of Female Leaders in India - Part IV: Visualizations and Correlations
Effect of Assassination of Leaders on Level of Democracy - Part I: Visualizations and Correlations

Interactive Graphs:
Random Sampling Creates a Representative Sample of the Target Population When Sample Size is Large Enough
How the Mean and Standard Deviation Change the Distribution of a Variable
The Two Characteristics the Correlation Coefficient Captures

CHAPTER 4: PREDICTING OUTCOMES USING LINEAR REGRESSION
In chapter 4, we learn how to predict outcomes using simple linear regression models. We analyze data from 170 countries to predict GDP growth using night-time light emissions as measured from space.

Code and Data Used in the Exercises in the Book:
Prediction.R (R script with the code) and countries.csv (CSV file with the data)

Lecture Slides:
Lecture 10. Predicting Non-Binary Outcomes with Linear Regression (Readings: 4-4.4.1, Video: How to Fit a Line to Predict Y Based on X)
Lecture 11. Predicting Binary Outcomes with Linear Regression (Readings: 4.6-4.9)
Lecture 12. Review

Questions Asked in the Additional Exercises Provided to Instructors Using DSS:
Predicting Course Grades - Part I: Predicting Final Exam Scores
Predicting Course Grades - Part II: Predicting Overall Scores
Predicting Course Grades - Part III: Predicting Probability of Earning an A or A-
Predicting Elections Using Betting Markets

Interactive Graphs:
The Role the Intercept and the Slope Play in Defining a Line
The Least Squares Method

CHAPTER 5: ESTIMATING CAUSAL EFFECTS WITH OBSERVATIONAL DATA
In chapter 5, we learn how to estimate causal effects using observational data. We analyze survey and electoral data to answer: What was the effect of Russian TV propaganda on the 2014 Ukrainian elections?

Code and Data Used in the Exercises in the Book:
Observational.R (R script with the code) and UA_survey.csv & UA_precincts.csv (CSV files with the data)

Lecture Slides:
Lecture 13. Estimating Causal Effects with Observational Data and the Problem of Confounders (Readings: 5-5.3.1)
Lecture 14. Controlling for Confounders Using Multiple Linear Regression (Readings: 5.3.2-5.4.2)
Lecture 15. Internal and External Validity (Readings: 5.5-5.7)
Lecture 16. Review

Questions Asked in the Additional Exercises Provided to Instructors Using DSS:
Effect of Black Candidates on Black Turnout
Effect of Assassination of Leaders on Level of Democracy - Part II: Fitting a Line to Compute the Difference-in-Means Estimator
Effect of Assassination of Leaders on Level of Democracy - Part III: Controlling for Confounders
Effect of Political TV Ads on Turnout

CHAPTER 6: PROBABILITY
In chapter 6, we cover basic probability. We learn about random variables and their distributions, the distinction between population parameters and sample statistics, and the two large sample theorems that enable us to measure statistical uncertainty.

Code and Data Used in the Exercises in the Book:
Probability.R (R script with the code)

Lecture Slides:
Lecture 19. Probability (Readings: 6-6.8)

Questions Asked in the Additional Exercises Provided to Instructors Using DSS:
Multiple-Choice Questions on Probability

Interactive Graphs:
The Law of Large Numbers (coming soon)
The Central Limit Theorem (coming soon)

CHAPTER 7: QUANTIFYING UNCERTAINTY
In chapter 7, we learn how to quantify the uncertainty in our empirical findings in order to draw conclusions at the population level. We complete some of the analyses we started in chapters 2 through 5.

Code and Data Used in the Exercises in the Book:
Uncertainty.R (R script with the code) and STAR.csv, BES.csv, countries.csv & UA_survey.csv  (CSV files with the data)

Lecture Slides:
Lecture 20. Hypothesis Testing with Estimated Regression Coefficients (Readings: 7-7.1, 7.3-7.6)
Lecture 21. Do Small Classes Increase Probability of Graduating
Lecture 22. Do Women Promote Different Policies Than Men?
Lecture 23. Does Social Pressure Affect Turnout?
Lecture 24. Is There Racial Discrimination in the Labor Market?