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

ECON120A: Problem Set 1

Exercise  1.  [15 points] Experimental and Observational Data

a) What is the main difference between experimental and observational data? Be specific about what is or is not being controlled in the two types of data.  [5 points]

Solution:   In an observational study we simply observe what happened in a particular situation.  We do not intervene the data generation process. In an experiment, researchers control the data generation.

b) Other than examples provided in class or in the textbook, describe an example of experimental study and an example of observational study. Briefly explain how the data is generated and collected [10 points].

Experimental:

Solution:  For example, a restaurant owner can set the meal price at different levels and see how the sales amount is influenced. Here the meal price is being controlled (X), and sales amount is being influenced (Y).

Observational:

Solution:  Almost all macro data are observational. For example, the GDP of U.S. from 2020:01 - 2020:12.

Exercise  2.  [10 points] Frequency distribution

The following raw data records the gender, race, and age of board of directors of a company in the U.S.

 

a) Produce a crosstabulation that shows the absolute frequencies of each type of race and gender.  [5 points] Solution:

 

b) Construct a percent frequency distribution for the race variable. What percentage of observations belongs to White?  [5 points]

Solution:

 

Exercise  3.  [15 points] Relative frequency

Western University has only one scholarship remaining for the coming year.  The nal two players that Western is considering are Allison Fealey and Emily Janson. The coaching staff has concluded that the speed and defensive skills are virtually identical for the two players, and that the nal decision will be based on which player has the best batting average.  Crosstabulations of each player’s batting performance in their junior and senior years of high school are as follows:

 

A player’s batting average is computed by dividing the number of hits a player has by the total number of at-bats. Batting averages are represented as a decimal number with three places after the decimal.

a) Calculate the batting average for each player in her junior year. Then calculate the batting average of each player in her senior year.  Using this analysis, which player should be awarded the scholarship?  Show

all your work.  [5 points]

Solution:

 

Allison has higher batting averages in both junior and senior years, so she should get the scholarship offer.

b) Combine or aggregate the data for the junior and senior years into one crosstabulation as follows:

 

Using this analysis, which player should be awarded the scholarship? Explain.  [5 points]

Solution:  The following table aggregates the data of junior and senior years

 

So the batting averages now become:

Allison: 90/290 = 0.310

Emily:  105/320 = 0.328

Emily has the higher batting average in two years, so she should get the scholarship offer.

c) Are the recommendations you made in parts (a) and (b) consistent?  Explain any apparent inconsis- tencies.  [5 points]

Solution:   Part  (a) and  (b) give opposite recommendations.   Although Emily did worse than Allison in Junior year, Emily’s performance in Junior year was pretty good, and most of her hits occurred in Junior year.  On the other hand, most of Allison’s hits occurred in her senior year, and her performance in senior year was not as good as Emily’s performance in Junior year. This is why when we combine the performances in both years, Emily outperforms Allison.

Exercise  4.  [25 points] Excel exercise: frequency table and bar chart

The percentage of the population working in the United States peaked in 2000 but dropped to the lowest level in 30 years in 2010. The data set, working.xlsx shows the percentage of the population working in each of the 50 states in 2010.  These percentages exclude military personnel and self-employed persons.  (data from the U.S. Census Bureau and U.S. Bureau of Labor Statistics.)

a) Construct a frequency distribution table. Group these data using ve classes of equal width of 5, with the starting point from 35.05.  [5 points]

Solution:  Follow these steps:

Step 1: Click on Insert → PivotChart

Step 2:  In the Input Range enter B1:B51, choose Existing Worksheet as the location, and enter D1 in the Location box (could be other blank cells)

Step 3: In the PivotChart Fields List on the right, drag the percent to Axis(Categories) area, and drag the percent eld to the Values area.

Step 4: Click on the Sum of percent in the Values area, select Count under summarize value eld by”       Step 5:  Right click on any cell containing an percent in the PivotTable, choose Group.  Enter 35.05 in the “Starting at”, 60.05 in the Ending at”, then 5 in the By” box.

Step 6: Click the Design tab under PivotChart Tools. Click Quick Layout button, and choose Layout 8.

Step 7: Change the axis names and title.

 

b) Based on the frequency distribution, do the data appear to be symmetric or skewed?  [5 points] Solution:  Data is moderately skewed to the right, as we have a right tail.

c) Calculate the relative frequencies and percent frequencies for all classes.  [5 points]

 

d) Produce a histogram.  [10 points]

Solution:   See steps in part a.   Since we have quantitative data,  the bars should be  adjacent to each other.

 

Exercise  5.  [25 points] Excel exercise: bar charts Electric plug-in vehicle sales have been increasing world- wide. The table below displays data collected by the U.S. Department of Energy on electric plug-in vehicle sales in the words top markets in 2013 and 2015.  (Data compiled by Argonne National Laboratory, U.S. Department of Energy website, https://www.energy.gov/eere/vehicles/fact-918-march-28-2016-global-plug- light-vehicle-sales-increased-about-80-2015)

 

a) Construct a side-by-side bar chart that compares the sales amount between 2013 and 2015 for each country. Comment on any trend in the display.  [10 points]

Solution:In every country sales of electric plug-in vehicle increased since  2013,  especially in  China  and Western Europe.

 

b) Convert the above table to percentage allocation for each year.  Construct a stacked bar chart with year as the variable on the horizontal axis (Your graph should show the percentage of each country in year 2013 and the percentage in year 2015).  [10 points]

Solution:  We can rst aggregate the total sale in year 2013 and year 2015:

 

Then we nd out the percentage of sales contributed by each country in both years:

 

To construct a bar chart, select the data, click Insert then choose stacked bar chart in recommended charts. If your data looks the same like above (i.e.  each row represents a country), go to Chart Design then click Switch Row/Column.

 

c) Is the display in part (a) or part (b) more insightful? Explain.  [5 points]

Solution:   Part a is more insightful if we want to look at the time trend in each region.   Part b shows the relative importance of each market in 2013 and 2015, although we do not see the absolute value of sales amount (Choosing either a or b is okay as long as a reasonable explanation is given).

Exercise  6.  [10 points] Excel exercise: scatter plot

For this exercise use the spreadsheet mortgage .xlsx. The data collects the information of past mortgages amount and the corresponding interest rate.

Construct a scatter plot and trendline.  Put mortgage amount on the horizontal axis, and interest rate on the vertical axis. What does your plot say about the relationship between the two variables?

Solution:   Select the data, click Insert, then nd scatter plot in Recommended Charts.  To add a trend- line, in Chart Design nd Add Chart Element then select linear trendline. Similarly, in Add Chart Element you can edit axis titles.

The plot suggests that the relationship between mortgage amount and interest rate is negative.