Specifications

Publication Date10th October, 2020 No. of Pages3 Assignment IDSA00002Price$25 USDDownloads01Note*Don't submit this file directly. if you need unique solution contact us

Description

---title: "Assignment 2"subtitle: "Econ 3210, Fall 2020"author: "Your name here"output: html_document---
```{r setup, include=FALSE}knitr::opts_chunk$set( echo = TRUE, message = FALSE, warning = FALSE)# Set the graphical themeggplot2::theme_set(ggplot2::theme_light())
library(AER)library(wooldridge)library(tidyverse)
```
## Question 1.
This data is based on the following paper:
K. Graddy (1997), "Do Fast-Food Chains Price Discriminate on the Race and IncomeCharacteristics of an Area?" Journal of Business and Economic Statistics 15, 391-401.
In the paper, the authors argue that fast food chains employ discriminatory pricing practices by charging higher amounts for common items in areas that have a higher proportion of African Americans (the variable **prpblck**).
a. What are the names of the variables in the **discrim** data?
```{r}# Your code here.discrim <- wooldridge::discrim
```
b. Consider the relationship below.
$$psoda_i = \beta_0 + \beta_1 prpblck_i + u_i$$
Run a simple regression to find the relationship between the price of soda (**psoda**) and the proportion of African Americans in a district (the variable **prpblck**).
Is there a significant correlation? Do you think that this represents a causal relationship?
```{r}# Your code here
```
d. Construct a 95 percent confidence interval for the coefficient on `prpblck`. What is the interpretation of a confidence interval?
```{r}# Your code here
```
## Question 2.
Using the data set `beauty` below. It contains the variable `wage` (hourly wage) and another variable `abvavg` that is a dummy variable for being "above average looking". This data is taken from an actual paper that looks at discrimination in the labour market.
```{r}beauty <- wooldridge::beauty
```
1. Use the command `table()` to tabulate the variable `abvavg`. This command tells you how many above average looking people are in the sample.
```{r}# Your code here
```
2. Consider the relationship$$wage_i = \beta_0 + \beta_1 abvavg + u_i$$What is the interpretation of $u_i$? What sorts of things could be in $u_i$.
> answer here
3. Estimate the relationship in (2). Interpret both the of the estimates of $\hat\beta_0$ and $\hat \beta_1$.
```{r}# code here
```
> answer here
4. Do beatiful people earn more than less beautiful people? (ie, is the coeffient $\hat \beta_1$ statistically significant)?
5. Now use the variable `belavg` instead `abvavg` in a regress. Is there a penalty for being below average looking (`belavg` is below average looking).
## Question 3.
Suppose we wanted to predict a CEO's salary based on the firms return on equity over the previous 2 years. The data set `ceosal` contains the variables `salary` (annual salary in thousands) and `roe`, the return on equity in percent (ie, return * 100). Consider the following equation:
$$salary_i = \beta_0 + \beta_1 roe_i + u_i$$
```{r}ceosal <- wooldridge::ceosal1```
1. Estimate the equation above and interpret the coefficient on $roe_i$. The units are important here -- the depednet variable is measured in thousands of dollars and $roe_i$ is in percent. Your interpretation should relate to these units of measurment. Discuss the test$$H_0: \beta_1 = 0 \\H_1: \beta_1 \neq 1$$
> answer here
2. In the following code chunck, I change the units of measurment. In particular, $roe\_decimal_i$ is $roe_i/100$ or measured as the return in decimals. The variable $salary\_dollars_i$ is salary measured in dollars rather than a thousands of dollars.
```{r}ceosal <- ceosal %>% mutate(roe_decimal = roe / 100, salary_dollars = salary * 1000)```
Estimate
$$salary\_dollars_i = \alpha_0 + \alpha_1 roe_i + u_i$$and
$$salary_i = \gamma_0 + \gamma_1 roe\_decimal_i + u_i$$in the code chunk below and interpret both the intercept and the slope coefficient. What is the relationship between $\beta_1$ and $\gamma_1$ and $\alpha_1$, and $\beta_0$ and $\gamma_0$ and $\alpha_0$```{r}# your code here
```
> answer here
3. Investigate the following hypothesis:
$$H_0: \gamma_1 = 0 \\H_1: \gamma_1 \neq 1$$Do our conclusions change from part 1?