Create a trajectory plot
Arguments
- data
A data frame like the outputs of
prep_trajectory().(Optional) If present, the column
labelis used for data labels.
- center_y
Logical. Use
TRUEto center the y-axis around start value (the default behavior ofqplot_trajectory()), or useFALSEto not center.- perc_y_scale
Logical.
FALSEdefaults to using no label conversion. UseTRUEto convert labels on y-axis to percentage usingscales::percent(the default behavior ofqplot_trajectory()).
See also
Other plotting functions:
plot_emission_intensity(),
plot_techmix(),
prep_emission_intensity(),
prep_techmix(),
prep_trajectory(),
qplot_emission_intensity(),
qplot_techmix(),
qplot_trajectory(),
recode_metric_techmix(),
recode_metric_trajectory(),
scale_colour_r2dii(),
scale_colour_r2dii_sector(),
scale_colour_r2dii_tech(),
scale_fill_r2dii(),
scale_fill_r2dii_sector(),
scale_fill_r2dii_tech(),
spell_out_technology(),
theme_2dii(),
to_title()
Examples
# plot with `qplot_trajectory()` parameters
data <- subset(
market_share_demo,
sector == "power" &
technology == "renewablescap" &
region == "global" &
scenario_source == "demo_2020"
)
data <- prep_trajectory(data)
plot_trajectory(
data,
center_y = TRUE,
perc_y_scale = TRUE
)
