JRC: R6 Class containing specific attributes and methods for...

JRCR Documentation

R6 Class containing specific attributes and methods for European Commission's Joint Research Centre data

Description

Class for downloading, cleaning and processing COVID-19 region data from the European Commission's Joint Research Centre. Subnational data (admin level 1) on numbers of contagious and fatalities by COVID-19, collected directly from the National Authoritative sources (National monitoring websites, when available). For more details see https://github.com/ec-jrc/COVID-19

Super classes

covidregionaldata::DataClass -> covidregionaldata::CountryDataClass -> JRC

Public fields

origin

name of origin to fetch data for

supported_levels

A list of supported levels.

supported_region_names

A list of region names in order of level.

supported_region_codes

A list of region codes in order of level.

level_data_urls

List of named links to raw data.

source_data_cols

existing columns within the raw data

source_text

Plain text description of the source of the data

source_url

Website address for explanation/introduction of the data

Methods

Public methods

Inherited methods

Method clean_common()

JRC specific data cleaning. The raw source data columns are converted to the correct type and renamed appropriately to match the standard for general processing.

Usage
JRC$clean_common()

Method clean_level_1()

JRC specific country level data cleaning. Selects country level (level 1) columns from the data ready for further processing.

Usage
JRC$clean_level_1()

Method clean_level_2()

JRC specific region level data cleaning. Selects country (level 1) and region (level 2) columns from the data ready for further processing.

Usage
JRC$clean_level_2()

Method clone()

The objects of this class are cloneable with this method.

Usage
JRC$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.

Source

https://github.com/ec-jrc/COVID-19

See Also

National data sources Covid19DataHub, ECDC, Google, JHU, WHO

Examples

## Not run: 
# get country level data
jrc_level_1 <- JRC$new(level = "1", verbose = TRUE, steps = TRUE, get = TRUE)
jrc_level_1$return()

# show available regions with data at the first level of interest (country)
jrc_level_1$available_regions()

# get region level data
jrc_level_2 <- JRC$new(level = "2", verbose = TRUE, steps = TRUE, get = TRUE)
jrc_level_2$return()

# show available regions with data at the second level of interest (region)
jrc_level_2$available_regions()

## End(Not run)

epiforecasts/covidregionaldata documentation built on June 26, 2022, 1 a.m.