Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit

Econ 773: Final exam

Feb 19, 2013 by 11:59 PM EST

Abstract

This is your final exam for Econ 773.  You can use any and all codes that you have seen in this course. This is an individual project . During the test, students may not discuss the test with anyone.  Any violation of this restriction will be treated as academic misconduct and will im- mediately be reported to the O¢ ce for Academic Integrity for possible sanctions which may include a 0 for the test, an F for the course with the transcript notation that the grade F was assigned for academic dishonesty and/or suspension or expulsion from your program and the university.

The output from regressions or data analysis can be too long, particularly  when  including  fixed  e§ects  (individual  factors). You want to be professional about it and not show all the out- put,  particularly  when  it  is  not  relevant to  what the  question is  asking  you.   To  hide  unnecessary  output  from  a  regression, you can suppress the output by adding {r echo = T, results = "hide"} to your code and then showing only the result for the coe¢ cient of interest.  How can you do this? First, you save your regression output and then write summary(your regression out- put  name)$coef[K,]  if it  is  the  coe¢ cient  on  the  Kth  variable that  you  are  interested  in).   It  is  also  professional  to  supress warning  message,  as  we  did  in  the  last  lecture.   Look  at  the

Rmarkdown files for Dinas _IV and for the answer to problem set 2.

You have to write your answers in RMarkdown, which will show both your code and your answers.  You have to include a Table of Contents similar to what it is done in the solutions to PS2 and to the Dinas_IV replication in Module 6.  Your submission should be written as a report, it should be clear and concise (one or two sentences per question su¢ ce in general).  Submit your answers as a pdf file.  You also have to sumbit

the Rmd file.

1    Problem 1

This is a replication of the results in Card and Krueger (1994) on the e§ects on employment of increasing the minimum wage.

Background: In April 1992, the minimum wage in New Jersey was raised from 4.25 USD to 5.05 USD. In Pennsylvania (the neighboring state), the min- imum wage remained constant at 4.25 USD. Card and Krueger (1994) analyze the impact of the minimum wage increase on employment in the fast-food in- dustry via di§erence-in-di§erences (DID). The authors found evidence that the increased minimum wage induced an increase in employment in New Jersey. Their finding stands in contrast to standard economic theory.

The authors collected data on the number of employees in 331 fast-food restaurants in New Jersey and 79 fast-food restaurants in Pennsylvania.  The survey was conducted in February 1992 (before the minimum wage was raised) and in November 1992 (after the minimum wage was raised).  The table below shows the average number of employees per restaurant:

February 1992    November 1992

New Jersey       17.1                     17.6

Pennsylvania    19.9                     17.5

Question 1 Why do you think that the authors chose to analyze employment in the fast-food industry, i.e. why this industry?

Question 2  Using only the numbers in the table above, there are three possible ways to estimate the causal e§ect of the wage increase on employment. Two such ways are comparing di§erence-in-means (DIMs) across the two states in February 1992 and comparing DIMs in November 1992. What is

the third approach? For each approach, discuss which assumptions have to be made in order for the DIM to recover the ATT.

Hint: Think about where the selection bias could come from for each DIM and

state an assumption that eliminates that.  You cannot assume that you have other data beyond that in the table, i.e. you cannot use instruments, covariates, propensity scores, etc.

The dataset m_wage.dta includes the information necessary to replicate the Card and Krueger analysis. First load the data into R. Since the data is in dta format, please type the following at the beginning of your code:

install.packages("haven")

require(haven)

data_card <- read_dta("/[address on your computer for the file]/m_wage.dta")

The dataset is stored in  a  ìwideî format,  i.e.   there is  a single row for each unit (restaurant), and di§erent columns for the outcomes and covariates in di§erent years. The dataset includes the following variables:

1.   nj ñ a dummy variable equal to  1 if the restaurant is located in New Jersey

2.   emptot ñ the total  number  of full-time  employed  people  in the  pre- treatment period

3.  emptot2 ñ the total number of full-time employed people in the post- treatment period

4. wage_st ña variable measuring the average starting wage in the restau- rant in the pre-treatment period

5. wage_st2 ña variable measuring the average starting wage in the restau- rant in the post-treatment period

6.   pmeal ñ a variable measuring the average price of a meal in the pre- treatment period

7.  pmeal2 ña variable measuring the average price of a meal in the post- treatment period

8. co_owned ña dummy variable equal to 1 if the restaurant was co-owned

9. bk ña dummy variable equal to 1 if the restaurant was a Burger King

10. kfc ña dummy variable equal to 1 if the restaurant was a KFC

11. wendys ña dummy variable equal to 1 if the restaurant was a Wendys

12. roys - a dummy variable equal to 1 if the restaurant was a Roy Rogers

You will need to load the read.dta function in the foreign package  (call library(foreign) before trying to call read.dta) to access this data.  After you load the foreign package, you can write:

m_wage <- read_dta([insert the address of the Öle on your computer and the name of the Öle])

After this, you can attach the data set by typing

attach(m_wage)

You donít have to do this, but it may make it easier to code because you do not have to always type the name of the Öle when you want to select a particular variable. Take a look at the example in Question 3 below.

In addition, note that there are some observations with missing data in this exercise (these are coded as NA in the data).  You can calculate all statistics (e.g., the mean of a vector) with missing values by setting the na.rm argument to be equal to TRUE in the statistics function. For example, take a look at the code in question 3 below.

Question 3  Calculate the percentage of Burger King, KFC, Roys, and Wendys in the sample. Show your results in a table similar to the one below:

Burger King KFC            Roy Rogers Wendys

New Jersey 41:09

Pennsylvania

44:3

Is the distribution of fast food restaurants comparable in the two states?

Hint: To compute the percentage of Burger King in Pennsylvania, I would do:

attach(m_wage)

njstore.bk=format(round(mean(bk[nj==1],na.rm=TRUE)*100,2),nsmall=1) Without attaching m_wage, we would need to write

njstore.bk=format(round(mean(m_wage$bk[nj==1],na.rm=TRUE)*100,2),nsmall=1)

When you compute the other numbers, call them:

.  For New Jersey: njstore.kfc (the percentage of KFC in New Jersey),

njstore.roys  (the % of Roy Rogers in New Jersey), njstore.wendys (the % of Wendys in New Jersey);

.  For Pennsylvania:  pastore.bk (the % of Burger King in Pennsylva- nia), pastore.kfc (the % of KFC in Pennsylvania), pastore.roys (the

% of Roy Rogers in Pennsylvania), pastore.wendys (the percentage of Wendys in Pennsylvania)

How can you create this table in R? After you calculate all 8 numbers, you can

write something like this:

ìë{r}

data_matrix= matrix(NA, ncol=2, nrow = 4) # creates a matrix with NA

colnames(data_matrix)  = c(íNew Jerseyí,íPennsylvaniaí)  # gives names to

columns

rownames(data_matrix) <- c(íBurger Kingí,íKFCí,íRoysí,íWendysí) # gives

names to rows

data_matrix[1,1] <- njstore.bk # Ölls the cell corresponding to column 1, row

1

data_matrix[2,1] <- njstore.kfc # Ölls the cell corresponding to column 1, row

2

# You have to Önish adding the other 6 numbers in the table.  For the cell

corresponding to column C, row R, you write data_matrix[R,C]

Önal=as.table(data_matrix) # assign to table

Önal # displays the table

ìë

Question 4  Calculate the di§erence-in-di§erence estimate for the average wage in NJ and PA. Remember that the wage is not the outcome of interest in

this case. What does this analysis suggest about the adoption rate of the minimum-wage policy in NJ?

Hint: To compute the pre-treatment di§erence in wages between NJ and PA, I would write

pre_treatment_di§erence <- mean(wage_st[nj ==1], na.rm = T) -  mean(wage_st[nj ==0], na.rm = T)

Question 5  Calculate the di§erence-in-di§erences estimator for the outcome of interest (the number of full-time employees).  Under what conditions does this estimate identify the average treatment e§ect on the treated? What evidence do you have to support or refute these conditions here? Think about whether you actually have any suggestive evidence at all.

Question 6  Calculate the di§erence-in-di§erences estimator for the price of an average meal.  Do restaurants that were subject to a wage increase raise their prices for fastñfood?

To run linear regression on this data, we have to convert the dataset from a ìwideîformat to a ìlongîformat (i.e.  where you have two observations for each restaurant, and an indicator for the time period in which the restaurant was observed).  Here is the code that converts the data so that we can use it with lm.

install.packages("tidyverse")

library(tidyverse)

min_wage_long <- m_wage %>%

select(nj,kfc,wendys,co_owned,wage_0=wage_st,emptot_0=emptot, wage_1=wage_st2,emptot_1=emptot2) %>%

pivot_longer(cols = c(wage_0,emptot_0,wage_1,emptot_1),

names_to = c(".value","treatment_period"),

names_sep = "_ ")

Question 7  Estimate the di§erence-in-di§erences ATT parameter using linear regression.   You  should run two  models:   one which only  includes the relevant variables to estimate the di§-in-di§, and one which additionally includes restaurant-level covariates which do not vary over time, e.g., kfc, wendys, co_owned. Do your estimates of the treatment e§ect di§er? Show your results for the interaction term only for the two regressions in the same table for ease of comparison using the huxtable package  (see the replication of the Dinas et al.  (2018) paper).  Note that you will need to show robust standard errors. You can use the jtools package for that.

2    Problem 2

This is a replication exercise of the results in Card (1994), "Using Geographic Variation in  College Proximity to Estimate the Return to  Schoolingî.   The working paper version and the data set can be found on A2L.1  For this problem, you will read the paper and then replicate Cardís results.   Please, try to be concise when you answer these questions (one or two sentences per answer should su¢ ce).

General  questions  about the  paper    (1a) What is the paper about? What is the main question addressed in the paper?

(1b) What is the most important Önding of the paper?

(1c) What is the main problem the paper deals with?  Explain why OLS is biased.

(1d) How does the author solve the problem? Brieáy explain the IV method.  (1e) Is the instrumental variable the author uses a convincing variable? What could be a counter-argument for why this variable may not be a convincing IV?

(1f) Explain the main results presented in Tables 4 and 5.

(1c) What may be some of the reasons for which the IV estimates are higher

than the OLS ones?

Replicating the results    Card (1994) uses data on a sample of 3010 work- ing men aged between 24 and 34 who were part of the 1976 wave of the US National Longitudinal Survey of Young Men (NLSY). The dataset includes:

.  log of hourly wages in 1976 (lwage),

. years of education (educ),

. years of labour market experience (exper),

. the square of years of labour market experience (expersq),                  .  a dummy variable equal to one if the individual is married (married), .  a dummy variable equal to one if the individual is black (black),

.  a dummy variable equal to one if the individual lives in the south in 1976 (south76),

.  a dummy variable equal to one if the individual lives in a standard metropol- itan statistical area in 1976 (smsa),

.  a dummy variable equal to one if the individual lived in a standard metropol- itan statistical area in 1966 (smsa66),

.  and nine regional dummy variables indicating where the individual lived in 1966 (reg661 ñreg669)

.  a dummy variable equal to one if the individual lived close to a college that o§ered 4 year courses in 1966 (nearc4).

A summary of all the variables in the data set is:

.  id person identiÖer

.  nearc2 =1 if near 2 yr college, 1966

.  nearc4 =1 if near 4 yr college, 1966

. educ years of schooling, 1976

.  age in years

.  fatheduc fatherís schooling

.  motheduc motherís schooling

. weight NLS sampling weight, 1976

.  momdad14 =1 if live with mom, dad at 14

.  sinmom14 =1 if with single mom at 14

.  step14 =1 if with step parent at 14

. reg661 =1 for region 1, 1966

. reg662 =1 for region 2, 1966

. reg663 =1 for region 3, 1966

. reg664 =1 for region 4, 1966

. reg665 =1 for region 5, 1966

. reg666 =1 for region 6, 1966

. reg667 =1 for region 7, 1966

. reg668 =1 for region 8, 1966

. reg669 =1 for region 9, 1966

.  south66 =1 if in south in 1966

. black =1 if black

.  smsa =1 in in SMSA, 1976

.  south =1 if in south, 1976

.  smsa66 =1 if in SMSA, 1966

. wage hourly wage in cents, 1976

. enroll =1 if enrolled in school, 1976

.  KWW knowledge world of work score

. IQ IQ score

.  married =1 if married, 1976

.  libcrd14 =1 if lib. card in home at 14

. exper = age - educ - 6

.  lwage log(wage)

. expersq = exper

First load the data into R. Since the data is in dta format, please type the following at the beginning of your code:

install.packages("haven")

require(haven)

data_card <- read_dta("/[address on your computer for the Öle]/card.dta")

2. After loading the data, produce descriptive statistics for your data similar to those of Table 1 (without row 9).  The data you have is from 1976, so you cannot replicate the results in Table 1 since Card uses data on 14-15 year olds, who are 24-25 years old in your data. Present your results in a table similar to Table 1:  means, standard deviations, maximum and minimum values of your variables.   Also, produce correlations between log(wage) and educ and exper and exper2 . Comment on these correlations.

3.   Estimate  an  OLS regression of log(wage)  (lwage) on educ exper ex- persq black south smsa reg661 reg662 reg663 reg664 reg665 reg666 reg667 reg668 smsa66. Compare your results to Table 2, Column (2) in Card (1995).

4. Estimate a reduced form equation for educ containing all covariates from part (1) above and the dummy variable nearc4. That is, regress educ on exper expersq black south smsa reg661 reg662 reg663 reg664 reg665 reg666 reg667 reg668 smsa66 nearc4. This is your Örst stage. Are educ and nearc4 statistically correlated? How about in reality: does it make sense to say that education and proximity to a 4-year college are correlated?  See also Table 3, column (1) in Card (1995).

5. Estimate now the log(wage) equation by IV, using nearc4 as an instrument for educ. That is, you have to do now the second-stage of 2SLS.

(a) Take your coe¢ cients from (4) above, and use them to predict education. Call the prediction educ_hat.

(b) Then regress lwage on educ_hat and exper expersq black south smsa reg661 reg662 reg663 reg664 reg665 reg666 reg667 reg668 smsa66. Compare the 95% conÖdence interval for the return to education with that obtained from part (1). See Table 3, Column (5) in Card (1994).

6. Use now both nearc2 and nearc4 as instruments for educ. First estimate

the reduced form for educ. This is just like (4) only that now you have an extra right-hand side variable that you need to include (which is nearc2).  Comment on whether nearc2 or nearc4 is more strongly correlated with educ.

7. Using your results from (6), do the second stage analysis where you regress lwage on the predicted education that you get using your results from (6). How do your 2SLS results compare with your earlier 2SLS results?  What are we learning from this?

8. For a subset of men, IQ score is also available. Regress IQ on nearc4. Is IQ correlated with nearc4?

9.  Now regress IQ on nearc4 reg661 reg662 reg663 reg669 smsa66.  Are IQ and neac4 partially correlated?  What can you conclude about the importance of controlling for the location in 1966 and the regional dummies in the log(wage) equation when using nearc4 as an IV for education?

10. We will extend Cardís results to allow the returns to education to di§er

by race.  Repeat all parts above by including the interaction term black · educ as an additional right hand side explanatory variable.  Then use black · nearc4 as the instrument (that is, replace nearc4 as an instrument by black · nearc4). Finally, for (6) and (7) use black · nearc4 and black · nearc2 as instruments.

3    Problem 3

Read the following two papers (available on A2L):

[1]  E.E. Leamer, Letís Take the Con Out of Econometrics, AER, 1983.

[2]  J.D. Angrist & J.-S. Pischke, The Credibility Revolution in Empirical Eco- nomics: How Better Research Design is Taking the Con out of Economet- rics, Journal of Economic Perspectives, 2010.

For paper [2] it is su¢ cient to read until p.18 (up to ìMad About Macroî). Answer the following questions about paper [1] and [2]:  (please provide short answers, say two or three sentences per answer):

(3a) What is the di§erence between a ìrandomized experimentîand a ìnatural experimentî, as discussed in [1]?

(3b)  Paper [1] says:  ìThe econometric art as it is practiced at the computer terminal involves Ötting many, perhaps thousands, of statistical models.î Explain why this might be a bad thing, and why this might be a good thing.

(3c)  Explain what is meant by ìsensitivity analysisîin paper [1].

(3d)  Explain what paper [2] means by ìnatural or quasi-experimentsî, and why it has a more positive view on those than paper [1]?

(3e) What is the main critique of paper [2] on the capital punishment study of Ehrlich (1975)?

(3f)  Explain why paper [2] criticizes the concept of ìsensitivity analysisî, as proposed in [1]?

(3g) What are they key solutions to the problem of credible inference proposed in [2]?

(3h)  Provide some reasons why the solutions advocated in [2] may not be fully satisfactory.

Comment: Papers [1] and [2] are part of a much larger intellectual debate. You should not view the  second paper  as the Önal conclusion of that debate.  For example, if you want, then you can also read the following additional papers, which will certainly help you to answer question (h):

[3]  E.E. Leamer,  Tantalus on the Road to Asymptopia, Journal of Eco- nomic Perspectives, 2010.

[4]  C.A. Sims, But Economics Is Not an Experimental Science, Journal of Economic Perspectives, 2010.

Podcasts: Closely related interviews by Russ Roberts with Ed Leamer and

Josh Angrist are available here:

http://www.econtalk.org/archives/2010/05/leamer_on_the_s.html http://www.econtalk.org/archives/2014/12/joshua_angrist.html

4    Problem 4

Suppose you have access to individual-level data on two regions in Mexico, re- gion A and region B. You observe the individuals living in these regions for four consecutive years (years 1, 2, 3, and 4). Both regions are poor and underdevel- oped.  Mobility between regions is not allowed.  The World Bank wants to test whether paying families for sending their children to school increases the prob- ability that children Önish eight grade. A World Bank team travels to region A and gives a cash transfer to the families living there in periods 3 and 4.  You are a development economist and you want to estimate the impact of the cash transfer program on the probability of Önishing eight grade.

(4a) Please describe how you would design a di§erence-in-di§erences ap- proach that you could use to estimate the impact of the cash transfer program.

(4b) Write down and explain the main di§erence-in-di§erences assumptions required to obtain reliable causal estimates.

(4c) What are the potential threats to identifying the causal e§ect of interest?

.  A very famous cash transfer program implemented in Mexico similar to the

one in this problem is called PROGRESA. If you are interested in devel- opment economics, it is a good idea to familiarize yourself with Progresa ñ this program is very famous and many developing countries implemented similar programs trying to replicate Progresaís results. You can read about Progresa in many papers, you could start with Parker and Todd (2017) (link on A2L).

(4d) A common way of doing a DID analysis in applied work is to consider the following linear outcome equation:

Yit  = a1 + a2 Ti + a3 Di + TTi Di + 9\ Xi + eit

where Ti  = 1 if i is observed in the post-treatment period and zero otherwise, and Di  = 1 if i is treated and zero otherwise.  The coe¢ cient T is interpreted as the ATT. However, this speciÖcation for the outcome implicitly imposes ad- ditional restrictions on the data generating process beyond parallel-paths con- ditional on Xi  and no anticipation conditional on Xi . What are these implicit assumptions?  (there are two of them).  When these additional restrictions are not satisÖed, the estimand T is, in general, di§erent from the ATT, and policy evaluation based on it may be misleading.