View source: R/transforms_to_dta.R
find_list_dta_observations | R Documentation |
This function returns a list of observations for which the Domestic Technology Assumption is applicable, in the format Country_Method_Energy.type_Last.stage_Year. See details for the process.
find_list_dta_observations(
.tidy_iea_df,
products_to_look_for = IEATools::products,
requirement_matrices_list = c(IEATools::psut_cols$Y, IEATools::psut_cols$U_eiou,
IEATools::psut_cols$U_feed),
country = IEATools::iea_cols$country,
method = IEATools::iea_cols$method,
energy_type = IEATools::iea_cols$energy_type,
last_stage = IEATools::iea_cols$last_stage,
year = IEATools::iea_cols$year,
flow = IEATools::iea_cols$flow,
product = IEATools::iea_cols$product,
imports = IEATools::interface_industries$imports,
matnames = IEATools::mat_meta_cols$matnames,
y_matrix = IEATools::psut_cols$Y,
u_eiou_matrix = IEATools::psut_cols$U_eiou,
u_feed_matrix = IEATools::psut_cols$U_feed,
v_matrix = IEATools::psut_cols$V,
r_matrix = IEATools::psut_cols$R
)
.tidy_iea_df |
The |
products_to_look_for |
The list of products that need to be looked for as consumed products.
Default is |
requirement_matrices_list |
The list of matrices where the |
country, method, energy_type, last_stage, year, product, flow |
See |
imports |
The name of imports flows in the |
matnames |
The column name for matrices names.
Default is |
y_matrix |
The name of the Y matrix.
Default is |
u_eiou_matrix |
The name of the U_EIOU matrix.
Default is |
u_feed_matrix |
The name of the U_feed matrix.
Default is |
v_matrix |
The name of the V matrix.
Default is |
r_matrix |
The name of the R matrix.
Default is |
Strictly speaking, the Domestic Technology Assumption can only be formulated when at least one unit of each consumed product (be it in the U_feed, U_eiou, or Y matrices) is produced domestically - i.e., appears at least once in the V matrix in a non-importing flow. The default run of the function is set up to return only those observations that fulfil such a requirement.
However, one may want to be more flexible about the formulation of the Domestic Technology Assumption. Indeed, nothing prevents from formulating the Domestic Technology Assumption in cases that do not fulfil the aforementioned conditions, but in that case, any demand for a given product that is not produced anywhere (be it direct or indirect demand) in the domestic economy will not be translated into any upstream demand, which is an important caveat.
The products_to_look_for
and requirement_matrices_list
offer additional flexibility, so that only products passed as argument to the products_to_look_for
argument
and matrices passed as arguments to the requirement_matrices_list
will act as constraining elements. Indeed, the new condition for formulation of the Domestic Technology
Assumption becomes that all products passed as products_to_look_for
argument and used one of the requirement_matrices_list
, must be produced at least once in the domestic
conversion chain (i.e. must appear in V in a non-importing flow).
A column specifying matrix name for each flows needs to be added before, most likely using the IEATools::add_psut_matnames()
function.
A list of observations for which the Domestic Technology Assumption is applicable. Each observation is defined as Country_Method_Energy.type_Last.stage_Year.
tidy_AB_data %>%
IEATools::add_psut_matnames() %>%
find_list_dta_observations()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.