Skip to contents

Makes a new regional or national country class with the name provided as the source. This forms a basic template for the user to fill in with the specific field values and cleaning functions required. This also creates a github workflow file for the same country.

Usage

make_new_data_source(
  source,
  type = "subnational",
  newfile_path = paste0("R/", source, ".R")
)

Arguments

source

character_array The name of the class to create. Must start with a capital letter (be upper camel case or an acronym in all caps such as WHO).

type

character_array the type of class to create, subnational or National defaults to subnational. Regional classes are individual countries, such as UK, Italy, India, etc. These inherit from DataClass, whilst national classes are sources for multiple countries data, such as JRC, JHU, Google, etc. These inherit from CountryDataClass.

newfile_path

character_array the place to save the class file