PSET4
NAME
2024-11-08
In this pset we’re going to continue our study of the effects of eviction on American families. This week we discussed how we can use observational data to ask causal questions. In this problem set we’re going to practice identifying and controlling for confounding variables in order to get better estimates for the average treatment effect.
In the code block below read in our data for this problem set: the debt dataset we’ve been working with for the past week. Also be sure to change the name of this problem set to your name both in the header above and with the filename. Remove NA observations in the debt dataset.
“‘{r}
# Pt 2: Identifying and Transforming Treatment and Outcome Variables (10 pts)
In this problem set we are interested in estimating the average causal effect of eviction on focal child
Pt 1: The code below creates a new variable in our debt dataset called “unsafe_perception”. This variabl
Note: Before you can compile this document you need to write code in the section above to read in the de
“`{r}
debt$unsafe_perception <- ifelse(debt$c.neigh_unsafe_day.15 == “Strongly agree” | debt$c.neigh_unsafe_nt.15 == “Strongly agree”, 1, 0)
Pt 2: In the bulleted list below, identify the treatment variable and the outcome variable for our research question. Identify both the name of the variable and give a substantive interpretation:
• Treatment:
• Outcome:
In this question we’re going to show that the difference-in-means estimate is equivalent to the slope on the treatment variable with simple linear regression.
Pt 1: Compute the difference-in-means estimate for our research question (the average causal effect of eviction on focal child’s perception of neighborhood safety). For the focal child’s perceptions be sure to use the new variable we created above. The estimate you should get is .075. You need to write code to produce this estimate.
Pt 2: Use the lm() function to fit a line to the data and summarize the relationship between the outcome variable Y and the treatment variable X.
“‘{r}
# Pt 4: Fitted Line (10 Pts)
What is the fitted line? In other words, provide the formula $hat{Y} = hat{alpha} + hat{beta}X$ whe
Note: it’s okay if your fitted line doesn’t have “hats.” You can just write the name of the variable in
# Pt 5: Interpretation (10 Pts)
Please provide a full substantive interpretation of the estimated slope coefficient and the estimated in
# Pt 6: Identifying Confounders (10 Pts)
Identify at least one variable in the debt dataset which may **confound** the relationship between evict
# Pt 7: Controlling for Confounders (10 Pts)
Estimate the average causal effect of eviction on childhood perceptions of safety, while controlling for
Hint: to fit a multiple linear regression model in R, we can use the function lm() and specify the main “`{r}
What is the fitted line? In other words, provide the formula Yˆ = αˆ + βˆ1X1 + βˆ2X2 where you specify each term (i.e. substitute Y for the name of the outcome variable, substitute αˆ for the estimated value of the intercept coefficient, substitute both βˆ terms for the estimated value of the slope coefficients, and substitute both Xs for the name of the treatment variable and confounder).
Note: If you choose a non-binary categorical variable for your confounder you will get more than two coefficients in your regression line. In lecture we discussed how to write and interpret a regression line with these additional coefficients.
Assuming the variable you identified is the only confounding variable, what is the average causal effect of eviction on child perceptions of neighborhood safety? Please write a full sentence answering the question, including the assumption, the treatment, the outcome, as well as the direction, size, and unit of measurement of the average treatment effect.
Describe below one other variable not included in the debt dataset that might confound the relationship between eviction and child perceptions of safety. We call these variables unobserved variables. Explain why this variable may confound the relationship. Remember, for a variable to confound a causal relationship it has to both have an effect on the treatment variable and have an effect on the outcome variable. Describe how this confounding variable may do this.
Why Work with Us
Top Quality and Well-Researched Papers
We always make sure that writers follow all your instructions precisely. You can choose your academic level: high school, college/university or professional, and we will assign a writer who has a respective degree.
Professional and Experienced Academic Writers
We have a team of professional writers with experience in academic and business writing. Many are native speakers and able to perform any task for which you need help.
Free Unlimited Revisions
If you think we missed something, send your order for a free revision. You have 10 days to submit the order for review after you have received the final document. You can do this yourself after logging into your personal account or by contacting our support.
Prompt Delivery and 100% Money-Back-Guarantee
All papers are always delivered on time. In case we need more time to master your paper, we may contact you regarding the deadline extension. In case you cannot provide us with more time, a 100% refund is guaranteed.
Original & Confidential
We use several writing tools checks to ensure that all documents you receive are free from plagiarism. Our editors carefully review all quotations in the text. We also promise maximum confidentiality in all of our services.
24/7 Customer Support
Our support agents are available 24 hours a day 7 days a week and committed to providing you with the best customer experience. Get in touch whenever you need any assistance.
Try it now!
How it works?
Follow these simple steps to get your paper done
Place your order
Fill in the order form and provide all details of your assignment.
Proceed with the payment
Choose the payment system that suits you most.
Receive the final file
Once your paper is ready, we will email it to you.
Our Services
No need to work on your paper at night. Sleep tight, we will cover your back. We offer all kinds of writing services.
Essays
No matter what kind of academic paper you need and how urgent you need it, you are welcome to choose your academic level and the type of your paper at an affordable price. We take care of all your paper needs and give a 24/7 customer care support system.
Admissions
Admission Essays & Business Writing Help
An admission essay is an essay or other written statement by a candidate, often a potential student enrolling in a college, university, or graduate school. You can be rest assurred that through our service we will write the best admission essay for you.
Reviews
Editing Support
Our academic writers and editors make the necessary changes to your paper so that it is polished. We also format your document by correctly quoting the sources and creating reference lists in the formats APA, Harvard, MLA, Chicago / Turabian.
Reviews
Revision Support
If you think your paper could be improved, you can request a review. In this case, your paper will be checked by the writer or assigned to an editor. You can use this option as many times as you see fit. This is free because we want you to be completely satisfied with the service offered.