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

Econ 452: PS4

2022

• If you have any questions regarding the PS, please email:          Eliane ([email protected]) or Shi ([email protected])

• You will be submitting two parts combined in one pdf file.  The first part will consists of your interpretation, proofs/derivations and answers to the questions which have been asked. This part must be typed up. The second part will be a Stata log file which will show all your code and the output you get from running your code. The results are the most important thing and hence should be read- able. All variables should have discernable labels in them, so that the tables are readable by anyone in your log file.

• Submitted problem sets which do not follow this format, or miss to submit one of the above two parts in their pdf file, will not get any credit.

• Requesting extensions on problem sets under extenuating circumstances:  You must email Eliane([email protected]) AND Shi([email protected]) and CC me with your registered official name and email NetID. If you are granted exten- sion then Eliane or Shi will set up your submission on onQ with your above

information. No problem sets will be accepted over emails.

In this problem set you will have to be a bit entrepreneurial.

Problem 1 We will run the fixed effects regression in different ways here. Pick any micro

level panel data set that you like.  You can use from Wooldridge datasets by searching for them on Google.  So your data should be at the unit-time level (where a unit i could be an individual or a firm observed over t time periods). You may have to create a variable which is a unit id, if the data does not have one for you to tell Stata which variable’s fixed effect to rake into account. Consider a model in which

Yit = β0 + β1Xit + µi + ϵit

Use Xit as controls of your choice which vary by both i and t. µi is the unit level fixed effect and is hence time invariant.

(a) Tell Stata what the panel variable (time variable) is by using xtset  . Run fixed effects estimation by running xtreg  command in Stata with the op- tion fe

(b) Repeat the above, but now cluster the standard errors at the unit level

(c) Now generate de-meaned variables (Yit − i) and (Xit − X¯i). You are aver- aging the variables by i across the time periods that they are observed. Use commands bysort  and egen  to generate these averages. Then subtract these averages from the variables to create the de-meaned variables. Now regress (Yit − i) on (Xit − X¯i)

(d) Repeat the above, but now cluster the standard errors at the unit level

(e) Now run a regression of Yiton Xit and a categorical variable for each unit i. i.e. run xi:    reg  y  x  i.unit_id

(f) Repeat the above, but now cluster the standard errors at the unit level

(g) How do all of these results compare?  Provide reasoning for the compar- isons.

Problem 2 We will implement a first difference estimation using a twins data adapted from

Ashenfelter Kreuger (1994).  Load twins90_adapted.dta.  The data is in a wide format i.e. each row has data on the logwage and education of two siblings for each twin-pair. 1 denotes data of sibling 1 and 2 denotes data of sibling 2.

(a) Generate dlogwage and deduc which are differences between logwages and

education of the 1st sibling from the 2nd.

(b) Run OLS of dlogwage on deduc

(c) Run OLS of dlogwage on deduc, without any constant term

(d) Are the coefficient estimates on deduc the same? Which of these regressions corresponds to first differencing the log wage equation to eliminate the twin fixed effects and why?

(e) Now reshape it to a long format. This will reshape the data such that there

will be two rows for each twin pair - one for sibling 1 and the next for sibling 2.  Run help  reshape  to learn more on how to do it.  Also see https://stats.oarc.ucla.edu/stata/modules/reshaping-data-wide-to-long/

(f) Tell Stata what the panel variable is by using xtset  .  Now use xtreg command with the fe  option to run fixed effects regression of log wages on education. Cluster your standard errors at the twin pair level. Interpret your results.

(g) Explain in words the assumptions needed to interpret these estimates as causal.