Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Homework Help/Study Tips Expert

Assignment 1: Data Analysis in R

1) Read the income dataset, "zipIncomeAssignment.csv", into R. (You can find the csv file in iLearn under the Content -> Week 2 folder.)

2) Change the column names of your data frame so that zcta becomes zipCode and meanhouseholdincome becomes income.

3) Analyze the summary of your data. What are the mean and median average incomes?

4) Plot a scatter plot of the data. Although this graph is not too informative, do you see any outlier values? If so, what are they?

5) In order to omit outliers, create a subset of the data so that:

$7,000 < income < $200,000 (or in R syntax , income > 7000 & income < 200000)

6) What's your new mean?

7) Create a simple box plot of your data. Be sure to add a title and label the axes.

In the box plot you created, notice that all of the income data is pushed towards the bottom of the graph because most average incomes tend to be low. Create a new box plot where the y-axis uses a log scale. Be sure to add a title and label the axes. For the next 2 questions, use the ggplot library in R, which enables you to create graphs with several different types of plots layered over each other.

8) Make a ggplot that consists of just a scatter plot using the function geom_point() with position = "jitter" so that the data points are grouped by zip code. Be sure to use ggplot's function for taking the log10 of the y-axis data. (Hint: for geom_point, have alpha=0.2).

9) Create a new ggplot by adding a box plot layer to your previous graph. To do this, add the ggplot function geom_boxplot(). Also, add color to the scatter plot so that data points between different zip codes are different colors. Be sure to label the axes and add a title to the graph. (Hint: for geom_boxplot, have alpha=0.1 and outlier.size=0).

10) What can you conclude from this data analysis/visualization?

Homework Help/Study Tips, Others

  • Category:- Homework Help/Study Tips
  • Reference No.:- M92836634

Have any Question?


Related Questions in Homework Help/Study Tips

Question assignment instructionsarticle critique select a

Question: Assignment Instructions Article Critique: Select a peer reviewed article that is focused on one of the following subject areas: 1. Port Security 2. Vulnerability of the Maritime Transportation Security (MTS) 3. ...

Case brief 71 in re yukos oil company securities

CASE BRIEF 7.1 : In re Yukos Oil Company Securities Litigation 2006 WL 3026024 (S.D.N.Y.) Questions: 1. Describe how Yukos is alleged to have saved significant amounts in taxes. 2. Explain what act of the Russian Federat ...

Discussion 2 child welfare and family preservationan

Discussion 2: Child Welfare And Family Preservation An essential aspect of social work practice is the support and preservation of the family unit. Building and empowering strong, resilient families is a focus of social ...

Do video games encourage sexist behavior please respond to

"Do Video Games Encourage Sexist Behavior?" Please respond to the following: Discuss one or two conflicting issues involving the view that video games encourage sexist behavior. Debate It - Take a position on this statem ...

Question primary task response within the discussion board

Question: Primary Task Response: Within the Discussion Board area, write 1,000 words that respond to the following questions with your thoughts, ideas, and comments. This will be the foundation for future discussions by ...

Question the web site amazoncom once aimed to be the worlds

Question: The Web site Amazon.com once aimed to be the world's largest bookseller. Now the company offers a wide range of products and services to consumers, operating online retail storefronts for partners and developin ...

Question not all ebp projects result in statistically

Question: Not all EBP projects result in statistically significant results. Define clinical significance, and explain the difference between clinical and statistical significance. How can you use clinical significance to ...

Qestion leadership styles and organizational design

Question: Leadership Styles and Organizational Design" Please respond to the following: • From the e-Activity, argue whether leaders are born or made. Give one (1) example of a great leader whom you admire in the health ...

Assignment -the topic chosen is molecular biologyproject

Assignment - The topic chosen is molecular biology. Project Outline and Project Development Paper - Part I: Project Outline This assignment is a step by step explanation of how your project will be developed from beginni ...

Question describe a specific example of groupthink you have

Question: Describe a specific example of groupthink you have witnessed in your personal or professional life. Explain what factors contributed to this example of groupthink and how the outcome may have been different had ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As