View source: R/transform_hep.R
transform_hep_data | R Documentation |
transform_hep_data()
applies transformations on HEP Billion indicators so
that transformed indicator values can be used within Billions calculations.
Details on the specific transformations applied can be found within the
Billions methods report.
transform_hep_data(
df,
scenario_col = NULL,
value_col = "value",
transform_glue = "transform_{value_col}",
source = "WUENIC/IVB/WHO Technical Programme",
ind_ids = billion_ind_codes("hep", include_calculated = TRUE),
extrapolate_to = 2025,
recycle = FALSE,
...
)
df |
Data frame in long format, where 1 row corresponds to a specific country, year, and indicator. |
scenario_col |
Column name of column with scenario identifiers. Useful for calculating contributions on data in long format rather than wide format. |
value_col |
Column name of column with indicator values. |
transform_glue |
Glue expression to be passed to |
source |
Source to use for prevent data that is flat extrapolated that has more than one unique value. |
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
|
extrapolate_to |
Year to extrapolate Prevent data to, defaults to 2025 |
recycle |
Boolean to indicate if data should be recycled |
... |
additional parameters to to pass to |
Currently, this function only changes Prevent campaign data by calculating the total sum of campaigns for each year for use in Prevent calculations. For more details on the HEP Billion calculation process and how this function ties in with the rest, see the vignette:
vignette("hep", package = "billionaiRe")
Data frame in long format.
HEP functions
add_hep_populations()
,
calculate_hep_billion()
,
calculate_hep_components()
,
hep_df
,
transform_prev_cmpgn_data()
,
transform_prev_routine_data()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.