decade_increase: Inter-decade Change in Emissions Plot

Description Usage Arguments Examples

View source: R/decade_increase.R

Description

decade_increase draws a plot of decade-to-decade change in total greenhouse gas emissions (carbon dioxide, methane and nitrous oxide) for the regions and decades provided as arguments. It also prints a table containing average emissions for each country throughout the years that span the decades provided in decades argument.

Usage

1
decade_increase(df, decades, regions)

Arguments

df

A dataframe containing annual carbon dioxide, methane and nitrous oxide emissions records by country or region. It must include variables iso_code, year, co2, methane and nitrous_oxide, where iso_code is a code uniquely identifying each region. The greenhouse gases emissions units should be in million tonnes of carbon dioxide-equivalents. One such dataframe can obtained from Our World in Data: https://github.com/owid/co2-data.

decades

A character vector containing the decades that should be included in the plot, in the format "1990-1999".

regions

A character vector containing the codes of countries and/or regions that should be included in the plot. The codes must match those of the df variable iso_code.

Examples

1
2
3
4
5
Greenhouse_Gas_Emissions <-
read.csv("https://raw.githubusercontent.com/owid/co2-data/master/owid-co2-data.csv")
decade_increase(Greenhouse_Gas_Emissions,
c("1990-1999", "1980-1989"),
c("USA", "GBR"))

omunizb/climate-change documentation built on Jan. 3, 2022, 12:15 a.m.