View source: R/scenarios_covid.R
scenario_covid_rapid_return | R Documentation |
scenario_covid_rapid_return()
creates a scenario where there is a rapid
return to the pre-pandemic situation after a dip due to COVID-19.
scenario_covid_rapid_return(
df,
start_year = 2018,
covid_year = 2020,
recovery_year = 2022,
end_year = 2025,
value_col = "value",
scenario_col = "scenario",
scenario_name = "covid_rapid_return",
ind_ids = billion_ind_codes("all"),
default_scenario = "default",
...
)
df |
Data frame in long format, where 1 row corresponds to a specific country, year, and indicator. |
start_year |
Base year for contribution calculation, defaults to 2018. |
covid_year |
(integer) year where the values are impacted by COVID. |
recovery_year |
integer year from which the AROC will be applied. Default to 2022. |
end_year |
End year(s) for contribution calculation, defaults to 2019 to 2025. |
value_col |
Column name of column with indicator values. This column will be used to return the results. |
scenario_col |
Column name of column with scenario identifiers. |
scenario_name |
name of scenario |
ind_ids |
Named vector of indicator codes for input indicators to the Billion.
Although separate indicator codes can be used than the standard, they must
be supplied as a named vector where the names correspond to the output of
|
default_scenario |
name of the default scenario. |
... |
additional parameters to be passed to
|
scenario |
name of scenario column to be created |
In details, the AROC between the start_year
and covid_year
- 1 is
applied to the last reported value to recovery_year
onward. If there are
missing values between covid_year
and recovery_year
, the last value from
covid_year
is carried forward. This applies only to countries where the
indicator value for covid_year
is reported
or estimated
. Otherwise,
the value is carried with scenario_bau
.
a data frame with scenario values in value_col
with a scenario_col
column.
COVID scenarios
scenario_covid_delayed_return()
,
scenario_covid_never_return()
,
scenario_covid_sustained_disruption()
,
scenario_dip_recover()
,
scenario_return_previous_trajectory()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.