View source: R/specify_tp_eiou.R
route_own_use_elect_chp_heat | R Documentation |
This function routes the "Own use in electricity, CHP and heat plants"
Energy Industry Own Use flow to each of the three electricity, CHP and heat
main activity producer plants.
The function is called within the specify_all()
function.
route_own_use_elect_chp_heat(
.tidy_iea_df,
split_using_shares_of = c("input", "output"),
country = IEATools::iea_cols$country,
flow_aggregation_point = IEATools::iea_cols$flow_aggregation_point,
flow = IEATools::iea_cols$flow,
ledger_side = IEATools::iea_cols$ledger_side,
method = IEATools::iea_cols$method,
energy_type = IEATools::iea_cols$energy_type,
last_stage = IEATools::iea_cols$last_stage,
year = IEATools::iea_cols$year,
product = IEATools::iea_cols$product,
unit = IEATools::iea_cols$unit,
e_dot = IEATools::iea_cols$e_dot,
supply = IEATools::ledger_sides$supply,
eiou = IEATools::aggregation_flows$energy_industry_own_use,
transformation_processes = IEATools::aggregation_flows$transformation_processes,
own_use_elect_chp_heat = IEATools::eiou_flows$own_use_elect_chp_heat_plants,
main_act_producer_elect = IEATools::main_act_plants$main_act_prod_elect_plants,
main_act_producer_chp = IEATools::main_act_plants$main_act_prod_chp_plants,
main_act_producer_heat = IEATools::main_act_plants$main_act_prod_heat_plants,
n_counting = ".n_counting",
destination_flow = ".destination_flow",
Total_main_activity_From_Func = ".Total_main_activity_From_Func",
Total_per_main_activity_From_Func = ".Total_per_main_activity_From_Func",
Share_per_main_activity_From_Func = ".Share_per_main_activity_From_Func"
)
.tidy_iea_df |
The |
split_using_shares_of |
A string that identifies which method is to be used for splitting the |
country |
The name of the country column in the |
flow_aggregation_point |
The name of the flow aggregation point column in the |
flow |
The name of the flow column in the |
ledger_side |
The name of the ledger side column in the |
method |
The name of the method column in the |
energy_type |
The name of the energy_type column in the |
last_stage |
The name of the last stage column in the |
year |
The name of the year column in the |
product |
The name of the product column in the |
unit |
The name of the unit column in the |
e_dot |
The name of the energy column in the |
supply |
A string identifying "Supply" in the |
eiou |
A string identifying "Energy industry own use" in the |
transformation_processes |
A string identifying transformation processes in the |
own_use_elect_chp_heat |
A string identifying "Own use in electricity, CHP and heat plants" in the |
main_act_producer_elect |
A string identifying "Main activity producer electricity plants" in the |
main_act_producer_chp |
A string identifying "Main activity producer CHP plants" in the |
main_act_producer_heat |
A string identifying "Main activity producer electricity plants" in the |
n_counting |
The name of a temporary column created in |
destination_flow |
The name of a temporary column created in |
Total_main_activity_From_Func |
The name of a temporary column created in |
Total_per_main_activity_From_Func |
The name of a temporary column created in |
Share_per_main_activity_From_Func |
The name of a temporary column created in |
The function either performs the routing using the share of outputs or of inputs of each of the three main activity producer industries.
The method is selected using the split_using_shares_of
argument,
to which either the have the "input" or "output" value can be passed.
When none of the main activity producer industries is present in the data frame, the "Own use in electricity, CHP and heat plants" flow is ascribed by default to the "Main activity producer electricity plant".
A modified version of the .tidy_iea_df
, in which the own_use_elect_chp_heat
flow has been routed to the main activity producer industries.
library(dplyr)
load_tidy_iea_df() %>%
route_own_use_elect_chp_heat()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.