load_exemplar_table: Read an exemplar table from an Excel file

View source: R/exemplar_functions.R

load_exemplar_tableR Documentation

Read an exemplar table from an Excel file

Description

An exemplar table has a column of country names and additional metadata, including the exemplar country and any name changes through time.

Usage

load_exemplar_table(
  exemplar_table_path = sample_exemplar_table_path(),
  countries = NULL,
  max_year = NULL,
  exemplar_table_tab_name = PFUWorkflow::exemplar_names$exemplar_tab_name,
  prev_names = PFUWorkflow::exemplar_names$prev_names,
  country = IEATools::iea_cols$country,
  year = IEATools::iea_cols$year
)

Arguments

exemplar_table_path

The path to the Excel file containing an exemplar table. Default is the value of sample_exemplar_table_path().

countries

The countries for which exemplars are desired. If NULL, the default, all countries in the file at exemplar_table_path are returned.

max_year

The maximum year for which you want the exemplar table, an integer. Default is NULL, meaning that all years from the file at exemplar_table_path are included.

exemplar_table_tab_name, prev_names

See PFUWorkflow::exemplar_names.

year, country

See IEATools::iea_cols.

Details

This function gathers (actually, tidyr::pivot_longer()) years into a Year column. It also

Value

an exemplar table

Examples

load_exemplar_table()

MatthewHeun/SEAPSUTWorkflow documentation built on April 22, 2022, 2:21 p.m.