Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please use R to write the following questions, What is the *proportion* of counties in each state that has had zero deaths? In other words:

Please use R to write the following questions,

  1. What is the *proportion* of counties in each state that has had zero deaths? In other words: in each state, how many counties have had 0 deaths (divided by the total number of counties in the state)? You should produce a *data frame* with columns `state` (containing the statename) and `proportion` (containing the ratio as a decimal), saving that data frame in a variable `proportion_no_deaths_df`.
  2. What proportion of counties in Washington state has had zero deaths? Use your `proportion_no_deaths` data frame, and save your result in `wa_prop_no_deaths`.

Notes:

data set source:

https://github.com/nytimes/covid-19-data/

Please read (us-counties.csv) data set above website and create data frame: "county_df" first

`tidyverse` package

Addition notes:

you can use the `group_by()` function to perform the same computation simultaneously across groups of rows. Your variables may need to include the specific column or value being asked for (use `pull()`).

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Algebra And Trigonometry

Authors: Cynthia Y Young

5th Edition

1119820898, 9781119820895

More Books

Students also viewed these Mathematics questions

Question

5. Describe the relationship between history and identity.

Answered: 1 week ago