Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Maintenance - Mise à jour mensuelle Lundi 6 Février entre 7h00 et 9h00
Open sidebar
UMR-ASTRE
Covid19-Mortality-Visualisation
Commits
4577542d
Commit
4577542d
authored
Jul 16, 2020
by
Renaud Lancelot
🌍
Browse files
Changes in the plan to account for changes in the datasets used in the analysis.
parent
f85acb8e
Pipeline
#15360
failed with stage
in 1 minute and 57 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/plan.R
View file @
4577542d
...
...
@@ -7,8 +7,7 @@ library(drake)
## ## loadd()
# The workflow plan data frame outlines what you are going to do.
plan
<-
drake_plan
(
## raw_data = read_excel(
plan
<-
drake_plan
(
## raw_data = read_excel(
## file_in(here("data/..."))
## ),
## clean_data = raw_data %>% cleanup(),
...
...
@@ -40,13 +39,15 @@ plan <- drake_plan(
"Georgia"
,
"Israel"
,
"Jordan"
,
"Lebanon"
,
"Libya"
,
"Moldova"
,
"Morocco"
,
"Syria"
,
"Tunisia"
,
"Ukraine"
),
europe
=
c
(
eu28
,
efta
,
candi
,
noneu
),
wca
=
c
(
"Cameroon"
,
"Central African Republic"
,
"Chad"
,
"Congo DR"
,
"Congo"
,
"Equatorial Guinea"
,
"Gabon"
,
"Sao Tome and Principe"
,
"Benin"
,
"Burkina Faso"
,
"Cape Verde"
,
"The Gambia"
,
"Ghana"
,
"Guinea"
,
"Guinea Bissau"
,
"C
o
te d'Ivoire"
,
"Liberia"
,
"Mali"
,
"Mauritania"
,
"Niger"
,
"Nigeria"
,
"Senegal"
,
"Sierra Leone"
,
"Togo"
),
"Congo DR"
,
"Congo"
,
"Equatorial Guinea"
,
"Gabon"
,
"Sao Tome and Principe"
,
"Benin"
,
"Burkina Faso"
,
"Cape Verde"
,
"The Gambia"
,
"Ghana"
,
"Guinea"
,
"Guinea Bissau"
,
"C
ô
te d'Ivoire"
,
"Liberia"
,
"Mali"
,
"Mauritania"
,
"Niger"
,
"Nigeria"
,
"Senegal"
,
"Sierra Leone"
,
"Togo"
),
## Total population counts and densities by Country, Year and Sex.
## Source: United Nations'[World Population Prospects
...
...
@@ -80,28 +81,33 @@ plan <- drake_plan(
lockdown
=
as.Date
(
lockdown
)
),
## Coronavirus Government Response Tracker
## Governments are taking a wide range of measures in response to
## the COVID-19 outbreak.
## This tool aims to track and compare
## policy responses around the world, rigorously and consistently.
# CARTOGRAPHY ---------------------------------------------------
lock
=
stringency
(),
## CARTOGRAPHY ---------------------------------------------------
world_map
=
get
Data
(
"countries"
),
world_map
=
get
_world_map
(
),
## GIS vector layer for European countries (EU 27 + UK + EFTA +
## candidate countries + non-EU countries). Source GADM.org
## version 3.6
geo_europe_light
=
readOGR
(
dsn
=
"data/geo_europe_light.gpkg"
,
layer
=
"geo_europe_light"
),
geo_europe_light
=
geosimplify
(
world_map
[
world_map
$
name
%in%
standardise_country_names
(
europe
),
]),
## GIS vector layer for the region of interest covering European
## countries described above
roi_europe_light
=
readOGR
(
dsn
=
"data/roi_europe_light.gpkg"
,
layer
=
"roi_europe_light"
),
roi_europe_light
=
region_of_interest
(
geo_europe_light
,
world_map
),
## GIS vector layer for West and Central African countries
geo
WCAfrica
=
world_map
[
world_map
$
ISO
%in%
get_iso3
(
wca
),]
%>
%
geosimplify
(
),
geo
wca
=
geosimplify
(
world_map
[
world_map
$
name
%in
%
standardise_country_names
(
wca
),]
),
roiWCAfrica
=
region_of_interest
(
geoWCAfrica
,
world_map
)
%>%
geosimplify
(),
roiwca
=
region_of_interest
(
geowca
,
world_map
),
## DERIVED DATA ----------------------------------------
...
...
@@ -136,7 +142,6 @@ plan <- drake_plan(
output_format
=
rmdformats
::
readthedown
(
dev
=
"png"
,
toc_depth
=
3
,
lightbox
=
T
,
gallery
=
T
,
use_bookdown
=
T
,
...
...
@@ -157,8 +162,7 @@ plan <- drake_plan(
includes
=
list
(
in_header
=
"preamble.tex"
,
before_body
=
"before_body.tex"
),
toc
=
T
,
toc_depth
=
3
,
classoption
=
"a4paper"
,
number_sections
=
T
,
latex_engine
=
"xelatex"
),
...
...
@@ -174,8 +178,6 @@ plan <- drake_plan(
output_format
=
bookdown
::
word_document2
(
dev
=
"png"
,
toc
=
T
,
toc_depth
=
3
,
number_sections
=
T
),
output_file
=
file_out
(
"public/covid19MortalityEurope.docx"
),
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment