Get Instant Help From 5000+ Experts For
question

Writing: Get your essay and assignment written from scratch by PhD expert

Rewriting: Paraphrase or rewrite your friend's essay with similar meaning at reduced cost

Editing:Proofread your work by experts and improve grade at Lowest cost

And Improve Your Grades
myassignmenthelp.com
loader
Phone no. Missing!

Enter phone no. to receive critical updates and urgent messages !

Attach file

Error goes here

Files Missing!

Please upload all relevant files for quick & complete assistance.

Guaranteed Higher Grade!
Free Quote
wave
Script to Analyze COVID-19 Data and Generate Plots for 6 Countries
Answered

Reading and Analyzing COVID-19 Data

You need to create a script that uses functions to perform the following:

1. A function to read the data from each file (reported and deaths) and store them in variables that can be used by other functions (i.e. the read function should pass the variables back to the main script).

2. A function to analyze the data, which should do the following (Note that each sub-part can be its own function, i.e. functions within functions):

a. Calculate the number of new cases (reported and deaths) daily in each country

b. Calculate the total number of cases (reported and deaths) worldwide for each day

c. Calculate the proportion of new cases (reported and deaths) based on the worldwide numbers for each day

d. Calculate the percentage increase / decrease of new cases (reported and deaths) on a daily basis for each country based on the previous day’s numbers for each country

e. Calculate the percentage increase / decrease of new cases (reported and deaths) for each country on a weekly basis (i.e. compare the numbers at the end of each week to the numbers at the end of the previous week)

f. Calculate the percentage of deaths to the number of reported cases on a day-today basis according to worldwide numbers (i.e. not country by country)

3. Now we need to choose a few countries to perform a deeper analysis and to visualize the data using plots. To do this, you need to do the following:

a. Choose 5 countries in addition to the United States that demonstrate the following behavior on the curves

i. Choose 2 countries that have the maximum day-to-day percentage increase

ii. Choose 2 countries that have the minimum day-to-day percentage increase

iii. Select any 1 country of your choice (need not be based on any analysis)

iv. If you use the week-by-week comparison for parts (i) and (ii) above, does the choice of your countries change? If so, why? If the choice changes, select those countries for all further analysis.

b. For these countries, scale their numbers (reported and deaths) by the population in those respective countries to obtain # of cases per 1 million population in each country. Use the website that I provided in the demo file to obtain the populations.

c. Calculate the percentage of deaths based on the number of reported cases in each of the 6 chosen countries on a day-to-day basis

4. Now we can plot the data to see what the curves look like. Using the scripts that I have provided in the demo file as a template, plot the following as a side-by-side plot (1 row, 2 columns as I have plotted in the demo file) unless otherwise stated and save them for including in the report (see note on saving plots below):

a. An evolution of reported cases on a day-to-day basis and the same with the deaths for all 6 countries (using actual case numbers)

b. An evolution of reported cases on a week-by-week basis for all 6 countries and the same with the deaths (using actual case numbers)

c. An evolution of the percentage change in those 6 countries on a day-to-day basis, same with deaths (using actual case numbers)

d. An evolution of the percentage change in those 6 countries on a week-by-week basis, same with deaths (using actual case numbers)

e. Evolution of reported cases and deaths on a day-to-day basis using the values that are scaled by the population in those countries

f. Evolution of the proportion of new cases per day based on worldwide numbers for both reported and deaths

g. Evolution of the percentage of deaths based on the number of reported cases in the 6 chosen countries on a day-to-day basis. To this plot, add the percentage of deaths based on the number of reported cases worldwide on a day-to-day basis.

support
Whatsapp
callback
sales
sales chat
Whatsapp
callback
sales chat
close