Hi everyone,
I'm working with a dataset that shows me the number of infected people with Covid-19 per day and per country. The data looks like:
country | 01/22/2020 | 01/23/2020 | 01/24/2020 | 01/25/2020 | 01/26/2020 | 01/27/2020 | 01/28/2020 | 01/29/2020
China | 4 | 7 | 16 | 30 | 60 | 100 | 150 | 200 |
US | 0 | 0 | 0 | 3 | 9 | 17 | 33 | 60 |
France | 0 | 1 | 9 | 20 | 40 | 70 | 100 | 110 |
Chile | 0 | 0 | 0 | 0 | 1 | 4 | 9 | 13 |
As you can see, each country differs in terms of when (which day) each one reported its first case of Covid-19. For example, China reported its first case on 22nd, US on 25th, France on 23rd, and Chile on 26th. Based on this fact, I would like to get the number of infected people of each country one week after its first case of Covid-19 (specifically, the 7-day-value).
I hope you can understand what I want to do. Thanks.
PD: this data is an example, I can't share the real data because there are so many variables and observations, but I have the number of infected people from 01/22/2020 to 04/30/2020.
PD2: each variable shows the number of infected people on that day. For example, on January 29th, China has 200 infected people, US 60 people, and go on. These observations are not the number of newly infected people per day.
Related Posts with Choosing the 7-day-value per country
Color changes with PNG export.On the left, we have the graph I actually want (ignore please the slight transparency difference bet…
Stata command for weighted M-estimator.Dear all, Does Stata has commands or packages that can estimate parameters for weighted M-estimator…
Formal tests of volatility in STATA17Dear Statlist: I have longitudinal data on employee data across multiple years and organizations. I…
Generating the "opposing" variable in a long datasetHi all, I am using Stata 17/SE on Mac and I am having trouble generating a variable using another o…
convert string yyyy-mm-dd hh:mm:ss to %td formatHello, As the title of this question suggests, I have a set of data with variable "Qtm" in string f…
Subscribe to:
Post Comments (Atom)
0 Response to Choosing the 7-day-value per country
Post a Comment