Skip to contents

Plot alignment timeline

Usage

plot_timeline(
  data,
  sector = NULL,
  scenario_source = NULL,
  scenario = NULL,
  region = NULL,
  group_var = NULL,
  title = NULL,
  subtitle = NULL,
  alignment_limits = NULL
)

Arguments

data

data.frame Should have the same format as output of prep_timeline() and contain columns: 'direction', 'year', 'exposure_weighted_net_alignment', and any column implied by group_var.

sector

Character. Sector name to be used in the plot title.

scenario_source

Character. Scenario source to be used in the plot caption.

scenario

Character. Scenario name to be used in the plot caption.

region

Character. Region to be used in the plot caption.

group_var

Character. Vector of length 1. Variable to group by.

title

Character. Custom title if different than default.

subtitle

Character. Custom subtitle if different than default.

alignment_limits

Numeric vector of size 2. Limits to be applied to alignment values for colouring. By default maximum absolute value of 'exposure_weighted_net_alignment' is used.

Value

object of type "ggplot"

Examples

# TODO