View source: R/target_market_share.R
target_market_share | R Documentation |
This function calculates the portfolio-level production targets, as calculated using the market share approach applied to each relevant climate production forecast.
target_market_share(
data,
abcd,
scenario,
region_isos = r2dii.data::region_isos,
use_credit_limit = FALSE,
by_company = FALSE,
weight_production = TRUE,
increasing_or_decreasing = r2dii.data::increasing_or_decreasing
)
data |
A "data.frame" like the output of |
abcd |
An asset level data frame like r2dii.data::abcd_demo. |
scenario |
A scenario data frame like r2dii.data::scenario_demo_2020. |
region_isos |
A data frame like r2dii.data::region_isos (default). |
use_credit_limit |
Logical vector of length 1. |
by_company |
Logical vector of length 1. |
weight_production |
Logical vector of length 1. |
increasing_or_decreasing |
A data frame like r2dii.data::increasing_or_decreasing. |
A tibble including the summarized columns metric
, production
,
technology_share
, percentage_of_initial_production_by_scope
and
scope
. If by_company = TRUE
, the output will also have the column
name_abcd
.
This function ignores existing groups and outputs ungrouped data.
Other functions to calculate scenario targets:
target_sda()
library(r2dii.data)
library(r2dii.match)
loanbook <- head(loanbook_demo, 100)
abcd <- head(abcd_demo, 100)
matched <- loanbook %>%
match_name(abcd) %>%
prioritize()
# Calculate targets at portfolio level
matched %>%
target_market_share(
abcd = abcd,
scenario = scenario_demo_2020,
region_isos = region_isos_demo
)
# Calculate targets at company level
matched %>%
target_market_share(
abcd = abcd,
scenario = scenario_demo_2020,
region_isos = region_isos_demo,
by_company = TRUE
)
matched %>%
target_market_share(
abcd = abcd,
scenario = scenario_demo_2020,
region_isos = region_isos_demo,
# Calculate unweighted targets
weight_production = FALSE
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.