hockeystick

Make essential Climate Change datasets easily available to non-climate experts.
https://github.com/cortinah/hockeystick

Category: Climate Change
Sub Category: Climate Data Access and Visualization

Keywords

carbon carbon-dioxide-data carbon-emissions climate climate-change climate-data climate-science ggplot2 methane noaa r rstats sea-ice sea-levels temperature-data warming-stripes

Last synced: about 7 hours ago
JSON representation

Repository metadata

Download and Visualize Essential Global Heating Data in R

README.md

hockeystick

Lifecycle: stable
R-CMD-check
CRAN status

The goal of hockeystick is to make essential Global Heating datasets
easily available in R to non-climate experts. hockeystick users can
download the latest raw data from authoritative sources as well as view
it via pre-defined ggplot2 charts. Datasets include climate projects
through 2100, atmospheric CO2 and CH4, carbon
emissions, instrumental, reconstructed, and paleo ice-core temperature
records, sea levels, hurricanes, and Arctic/Antarctic sea-ice.

The choice of data was originally based on Professor Stefan
Rahmstorf’s
presentation on The 5
Most Important Data Sets of Climate
Science
. I
came across this on a post on the Open Mind
blog
.
I wrote my own
post
on obtaining and visualizing this data (now out of date), which is the
basis for this package. Additional datasets and visualizations have been
added over The name of the package stems from the well known
hockeystick
temperature chart.

hockeystick was highlighted on the RStudio
RViews
blog by Joseph Rickert as one of the “Top 40” new packages on CRAN in
February 2021.

New in version 1.0.0: Retrieve and plot global maps of future cmip6
projections from WorldClim.

New in version 0.9.0: Global wildfire area burnt and emissions data from
GWIS.

Installation

To install the latest hockeystick release from CRAN type:

install.packages("hockeystick")

You may alternatively install the development version from
https://github.com/cortinah/hockeystick with:

pak::pak("cortinah/hockeystick@testing")

Downloading and viewing global heating data

Plot daily global temperatures since 1940 and current anomaly:

library(hockeystick)
globaldaily <- get_dailytempcop()
plot_dailytemp(globaldaily)

Retrieve NOAA/ESRL Mauna Loa CO2 Observatory concentration
data and plot:

ml_co2 <- get_carbon()
plot_carbon(ml_co2)

Retrieve 2081-2100 temperature projections and map:

proj <- get_cmip6()
plot_cmip6(proj)

Retrieve 2081-2100 precipation anomaly and map:

anom <- get_cmip6_anom(var = 'prec')
plot_cmip6_anom(anom)

Retrieve GCP global CO2 emissions and plot:

emissions <- get_emissions()
plot_emissions(emissions)
plot_emissions_with_land(emissions)

Visualize cumulative emissions by country:

emissions_map()

Retrieve NASA/GISS global surface temperature anomaly data and plot:

anomaly <- get_temp()
plot_temp(anomaly)

Plot relationship between temperature anomaly and carbon:

plot_carbontemp()

Visualize warming using Ed Hawkins styled “warming stripes”:

warming_stripes()
warming_stripes(stripe_only = TRUE, col_strip = viridisLite::viridis(11))

Retrieve tide gauge and satellite sea level data and plot:

gmsl <- get_sealevel()
plot_sealevel(gmsl)

Retrieve July annual Arctic Sea Ice Index and plot:

seaice <- get_seaice()
plot_seaice(seaice)

get_seaice() arguments can be modified to download Antarctic sea ice,
and allow any month.

You can also visualize sea ice by month and year:

arcticice <- get_icecurves()
plot_icecurves(arcticice)

Retrieve Common Era temperature reconstruction and plot it with
instrumental record:

anomaly2k <- get_temp2k()
plot_temp2k(anomaly2k)

Retrieve NOAA HURDAT2 hurricane data and plot:

hurricanes <- get_hurricanes()
plot_hurricanes(hurricanes)
plot_hurricane_nrg(hurricanes)

Retrieve GWIS wildfire data and plot:

usfires <- get_fires_area(place='USA', year = 2026)
plot_fires_area(usfires)
plot_fires_area(usfires, style = 'weekly')

Retrieve NOAA/ESRL CH4 Globally averaged mean data and plot:

ch4 <- get_methane()
plot_methane(ch4)

Retrieve Vostok paleo ice core data and plot:

vostok <- get_paleo()
plot_paleo(vostok)

Managing the cache

By default, no climate data is cached, and all data is downloaded every
time any of the get_ functions is called. To cache data for future
use, use the write_cache = TRUE option, available in all of the get_
functions. To download and cache all data use
hockeystick_update_all(). To view the files, date, and size of cached
data use hockeystick_cache_details(). To re-download data from the
source use the use_cache = FALSE argument in any of the get_
functions, for example:
get_carbon(use_cache = FALSE, write_cache = TRUE). To delete all
cached data use hockeystick_cache_delete_all().

Users may also cache data by default by adding
options(hs_write_cache = TRUE)to their script or .Rprofile file.

All together now: climate data grid

climate_grid()

Acknowledgments

Notes and resources

Citation (CITATION.cff)

# --------------------------------------------
# CITATION file created with {cffr} R package
# See also: https://docs.ropensci.org/cffr/
# --------------------------------------------

cff-version: 1.2.0
message: 'To cite package "hockeystick" in publications use:'
type: software
license: MIT
title: 'hockeystick: Download and Visualize Essential Climate Change Data'
version: 0.8.7
identifiers:
- type: doi
  value: 10.32614/CRAN.package.hockeystick
abstract: 'Provides easy access to essential climate change datasets to non-climate
  experts. Users can download the latest raw data from authoritative sources and view
  it via pre-defined ''ggplot2'' charts. Datasets include atmospheric CO2, methane,
  emissions, instrumental and proxy temperature records, sea levels, Arctic/Antarctic
  sea-ice, Hurricanes, and Paleoclimate data. Sources include: NOAA Mauna Loa Laboratory
  <https://gml.noaa.gov/ccgg/trends/data.html>, Global Carbon Project <https://www.globalcarbonproject.org/carbonbudget/>,
  NASA GISTEMP <https://data.giss.nasa.gov/gistemp/>, National Snow and Sea Ice Data
  Center <https://nsidc.org/home>, CSIRO <https://research.csiro.au/slrwavescoast/sea-level/measurements-and-data/sea-level-data/>,
  NOAA Laboratory for Satellite Altimetry <https://www.star.nesdis.noaa.gov/socd/lsa/SeaLevelRise/>
  and HURDAT Atlantic Hurricane Database <https://www.aoml.noaa.gov/hrd/hurdat/Data_Storm.html>,
  Vostok Paleo carbon dioxide and temperature data: <https://doi.org/10.3334/CDIAC/ATG.009>.'
authors:
- family-names: Cortina
  given-names: Hernando
  email: hch@alum.mit.edu
  orcid: https://orcid.org/0000-0001-6790-4870
preferred-citation:
  type: manual
  title: 'hockeystick: Download and Visualize Essential Climate Change Data'
  authors:
  - family-names: Cortina
    given-names: Hernando
    email: hch@alum.mit.edu
    orcid: https://orcid.org/0000-0001-6790-4870
  year: '2020'
  url: https://cortinah.github.io/hockeystick/
repository: https://CRAN.R-project.org/package=hockeystick
repository-code: https://github.com/cortinah/hockeystick
url: https://cortinah.github.io/hockeystick/
contact:
- family-names: Cortina
  given-names: Hernando
  email: hch@alum.mit.edu
  orcid: https://orcid.org/0000-0001-6790-4870
keywords:
- carbon
- carbon-dioxide-data
- carbon-emissions
- climate
- climate-change
- climate-data
- climate-science
- ggplot2
- methane
- noaa
- r
- rstats
- sea-ice
- sea-levels
- temperature-data
- warming-stripes
references:
- type: software
  title: ggplot2
  abstract: 'ggplot2: Create Elegant Data Visualisations Using the Grammar of Graphics'
  notes: Imports
  url: https://ggplot2.tidyverse.org
  repository: https://CRAN.R-project.org/package=ggplot2
  authors:
  - family-names: Wickham
    given-names: Hadley
    email: hadley@posit.co
    orcid: https://orcid.org/0000-0003-4757-117X
  - family-names: Chang
    given-names: Winston
    orcid: https://orcid.org/0000-0002-1576-2126
  - family-names: Henry
    given-names: Lionel
  - family-names: Pedersen
    given-names: Thomas Lin
    email: thomas.pedersen@posit.co
    orcid: https://orcid.org/0000-0002-5147-4711
  - family-names: Takahashi
    given-names: Kohske
  - family-names: Wilke
    given-names: Claus
    orcid: https://orcid.org/0000-0002-7470-9261
  - family-names: Woo
    given-names: Kara
    orcid: https://orcid.org/0000-0002-5125-4188
  - family-names: Yutani
    given-names: Hiroaki
    orcid: https://orcid.org/0000-0002-3385-7233
  - family-names: Dunnington
    given-names: Dewey
    orcid: https://orcid.org/0000-0002-9415-4582
  - family-names: Brand
    given-names: Teun
    name-particle: van den
    orcid: https://orcid.org/0000-0002-9335-7468
  year: '2026'
  doi: 10.32614/CRAN.package.ggplot2
- type: software
  title: lubridate
  abstract: 'lubridate: Make Dealing with Dates a Little Easier'
  notes: Imports
  url: https://lubridate.tidyverse.org
  repository: https://CRAN.R-project.org/package=lubridate
  authors:
  - family-names: Spinu
    given-names: Vitalie
    email: spinuvit@gmail.com
  - family-names: Grolemund
    given-names: Garrett
  - family-names: Wickham
    given-names: Hadley
  year: '2026'
  doi: 10.32614/CRAN.package.lubridate
- type: software
  title: tools
  abstract: 'R: A Language and Environment for Statistical Computing'
  notes: Imports
  authors:
  - name: R Core Team
    website: https://ror.org/02zz1nj61
  institution:
    name: R Foundation for Statistical Computing
    website: https://ror.org/05qewa988
    address: Vienna, Austria
  year: '2026'
  doi: 10.32614/R.manuals
- type: software
  title: readr
  abstract: 'readr: Read Rectangular Text Data'
  notes: Imports
  url: https://readr.tidyverse.org
  repository: https://CRAN.R-project.org/package=readr
  authors:
  - family-names: Wickham
    given-names: Hadley
    email: hadley@posit.co
  - family-names: Hester
    given-names: Jim
  - family-names: Bryan
    given-names: Jennifer
    email: jenny@posit.co
    orcid: https://orcid.org/0000-0002-6983-2759
  year: '2026'
  doi: 10.32614/CRAN.package.readr
- type: software
  title: dplyr
  abstract: 'dplyr: A Grammar of Data Manipulation'
  notes: Imports
  url: https://dplyr.tidyverse.org
  repository: https://CRAN.R-project.org/package=dplyr
  authors:
  - family-names: Wickham
    given-names: Hadley
    email: hadley@posit.co
    orcid: https://orcid.org/0000-0003-4757-117X
  - family-names: François
    given-names: Romain
    orcid: https://orcid.org/0000-0002-2444-4226
  - family-names: Henry
    given-names: Lionel
  - family-names: Müller
    given-names: Kirill
    orcid: https://orcid.org/0000-0002-1416-3412
  - family-names: Vaughan
    given-names: Davis
    email: davis@posit.co
    orcid: https://orcid.org/0000-0003-4777-038X
  year: '2026'
  doi: 10.32614/CRAN.package.dplyr
- type: software
  title: tidyr
  abstract: 'tidyr: Tidy Messy Data'
  notes: Imports
  url: https://tidyr.tidyverse.org
  repository: https://CRAN.R-project.org/package=tidyr
  authors:
  - family-names: Wickham
    given-names: Hadley
    email: hadley@posit.co
  - family-names: Vaughan
    given-names: Davis
    email: davis@posit.co
  - family-names: Girlich
    given-names: Maximilian
  year: '2026'
  doi: 10.32614/CRAN.package.tidyr
- type: software
  title: patchwork
  abstract: 'patchwork: The Composer of Plots'
  notes: Imports
  url: https://patchwork.data-imaginist.com
  repository: https://CRAN.R-project.org/package=patchwork
  authors:
  - family-names: Pedersen
    given-names: Thomas Lin
    email: thomasp85@gmail.com
    orcid: https://orcid.org/0000-0002-5147-4711
  year: '2026'
  doi: 10.32614/CRAN.package.patchwork
- type: software
  title: scales
  abstract: 'scales: Scale Functions for Visualization'
  notes: Imports
  url: https://scales.r-lib.org
  repository: https://CRAN.R-project.org/package=scales
  authors:
  - family-names: Wickham
    given-names: Hadley
    email: hadley@posit.co
  - family-names: Pedersen
    given-names: Thomas Lin
    email: thomas.pedersen@posit.co
    orcid: https://orcid.org/0000-0002-5147-4711
  - family-names: Seidel
    given-names: Dana
  year: '2026'
  doi: 10.32614/CRAN.package.scales
- type: software
  title: rvest
  abstract: 'rvest: Easily Harvest (Scrape) Web Pages'
  notes: Imports
  url: https://rvest.tidyverse.org/
  repository: https://CRAN.R-project.org/package=rvest
  authors:
  - family-names: Wickham
    given-names: Hadley
    email: hadley@posit.co
  year: '2026'
  doi: 10.32614/CRAN.package.rvest
- type: software
  title: tibble
  abstract: 'tibble: Simple Data Frames'
  notes: Imports
  url: https://tibble.tidyverse.org/
  repository: https://CRAN.R-project.org/package=tibble
  authors:
  - family-names: Müller
    given-names: Kirill
    email: kirill@cynkra.com
    orcid: https://orcid.org/0000-0002-1416-3412
  - family-names: Wickham
    given-names: Hadley
    email: hadley@rstudio.com
  year: '2026'
  doi: 10.32614/CRAN.package.tibble
- type: software
  title: treemapify
  abstract: 'treemapify: Draw Treemaps in ''ggplot2'''
  notes: Imports
  url: https://wilkox.org/treemapify/
  repository: https://CRAN.R-project.org/package=treemapify
  authors:
  - family-names: Wilkins
    given-names: David
    email: david@wilkox.org
    orcid: https://orcid.org/0000-0002-3385-8981
  year: '2026'
  doi: 10.32614/CRAN.package.treemapify
- type: software
  title: RColorBrewer
  abstract: 'RColorBrewer: ColorBrewer Palettes'
  notes: Imports
  repository: https://CRAN.R-project.org/package=RColorBrewer
  authors:
  - family-names: Neuwirth
    given-names: Erich
    email: erich.neuwirth@univie.ac.at
  year: '2026'
  doi: 10.32614/CRAN.package.RColorBrewer
- type: software
  title: jsonlite
  abstract: 'jsonlite: A Simple and Robust JSON Parser and Generator for R'
  notes: Imports
  url: https://jeroen.r-universe.dev/jsonlite
  repository: https://CRAN.R-project.org/package=jsonlite
  authors:
  - family-names: Ooms
    given-names: Jeroen
    email: jeroenooms@gmail.com
    orcid: https://orcid.org/0000-0002-4035-0289
  year: '2026'
  doi: 10.32614/CRAN.package.jsonlite
- type: software
  title: readxl
  abstract: 'readxl: Read Excel Files'
  notes: Imports
  url: https://readxl.tidyverse.org
  repository: https://CRAN.R-project.org/package=readxl
  authors:
  - family-names: Wickham
    given-names: Hadley
    email: hadley@posit.co
    orcid: https://orcid.org/0000-0003-4757-117X
  - family-names: Bryan
    given-names: Jennifer
    email: jenny@posit.co
    orcid: https://orcid.org/0000-0002-6983-2759
  year: '2026'
  doi: 10.32614/CRAN.package.readxl
- type: software
  title: 'R: A Language and Environment for Statistical Computing'
  notes: Depends
  url: https://www.R-project.org/
  authors:
  - name: R Core Team
    website: https://ror.org/02zz1nj61
  institution:
    name: R Foundation for Statistical Computing
    website: https://ror.org/05qewa988
    address: Vienna, Austria
  year: '2026'
  doi: 10.32614/R.manuals
  version: '>= 4.1.0'
- type: software
  title: rmarkdown
  abstract: 'rmarkdown: Dynamic Documents for R'
  notes: Suggests
  url: https://pkgs.rstudio.com/rmarkdown/
  repository: https://CRAN.R-project.org/package=rmarkdown
  authors:
  - family-names: Allaire
    given-names: JJ
    email: jj@posit.co
  - family-names: Xie
    given-names: Yihui
    email: xie@yihui.name
    orcid: https://orcid.org/0000-0003-0645-5666
  - family-names: Dervieux
    given-names: Christophe
    email: cderv@posit.co
    orcid: https://orcid.org/0000-0003-4474-2498
  - family-names: McPherson
    given-names: Jonathan
    email: jonathan@posit.co
  - family-names: Luraschi
    given-names: Javier
  - family-names: Ushey
    given-names: Kevin
    email: kevin@posit.co
  - family-names: Atkins
    given-names: Aron
    email: aron@posit.co
  - family-names: Wickham
    given-names: Hadley
    email: hadley@posit.co
  - family-names: Cheng
    given-names: Joe
    email: joe@posit.co
  - family-names: Chang
    given-names: Winston
    email: winston@posit.co
  - family-names: Iannone
    given-names: Richard
    email: rich@posit.co
    orcid: https://orcid.org/0000-0003-3925-190X
  year: '2026'
  doi: 10.32614/CRAN.package.rmarkdown
- type: software
  title: knitr
  abstract: 'knitr: A General-Purpose Package for Dynamic Report Generation in R'
  notes: Suggests
  url: https://yihui.org/knitr/
  repository: https://CRAN.R-project.org/package=knitr
  authors:
  - family-names: Xie
    given-names: Yihui
    email: xie@yihui.name
    orcid: https://orcid.org/0000-0003-0645-5666
  year: '2026'
  doi: 10.32614/CRAN.package.knitr
- type: software
  title: viridisLite
  abstract: 'viridisLite: Colorblind-Friendly Color Maps (Lite Version)'
  notes: Suggests
  url: https://sjmgarnier.github.io/viridisLite/
  repository: https://CRAN.R-project.org/package=viridisLite
  authors:
  - family-names: Garnier
    given-names: Simon
    email: garnier@njit.edu
  year: '2026'
  doi: 10.32614/CRAN.package.viridisLite
- type: software
  title: svglite
  abstract: 'svglite: An ''SVG'' Graphics Device'
  notes: Suggests
  url: https://svglite.r-lib.org
  repository: https://CRAN.R-project.org/package=svglite
  authors:
  - family-names: Wickham
    given-names: Hadley
    email: hadley@posit.co
  - family-names: Henry
    given-names: Lionel
    email: lionel@posit.co
  - family-names: Pedersen
    given-names: Thomas Lin
    email: thomas.pedersen@posit.co
    orcid: https://orcid.org/0000-0002-5147-4711
  - family-names: Luciani
    given-names: T Jake
    email: jake@apache.org
  - family-names: Decorde
    given-names: Matthieu
    email: matthieu.decorde@ens-lyon.fr
  - family-names: Lise
    given-names: Vaudor
    email: lise.vaudor@ens-lyon.fr
  year: '2026'
  doi: 10.32614/CRAN.package.svglite

Owner metadata


GitHub Events

Total
Last Year

Committers metadata

Last synced: 1 day ago

Total Commits: 168
Total Committers: 2
Avg Commits per committer: 84.0
Development Distribution Score (DDS): 0.22

Commits in past year: 4
Committers in past year: 1
Avg Commits per committer in past year: 4.0
Development Distribution Score (DDS) in past year: 0.0

Name Email Commits
Hernando Cortina h****h@a****u 131
Hernando h****h@a****u 37

Committer domains:


Issue and Pull Request metadata

Last synced: 14 days ago

Total issues: 12
Total pull requests: 28
Average time to close issues: 4 months
Average time to close pull requests: 6 minutes
Total issue authors: 2
Total pull request authors: 1
Average comments per issue: 1.5
Average comments per pull request: 0.0
Merged pull request: 23
Bot issues: 0
Bot pull requests: 0

Past year issues: 0
Past year pull requests: 7
Past year average time to close issues: N/A
Past year average time to close pull requests: 5 minutes
Past year issue authors: 0
Past year pull request authors: 1
Past year average comments per issue: 0
Past year average comments per pull request: 0.0
Past year merged pull request: 4
Past year bot issues: 0
Past year bot pull requests: 0

More stats: https://issues.ecosyste.ms/repositories/lookup?url=https://github.com/cortinah/hockeystick

Top Issue Authors

  • cortinah (11)
  • carbonmetrics (1)

Top Pull Request Authors

  • cortinah (28)

Top Issue Labels

Top Pull Request Labels


Package metadata

proxy.golang.org: github.com/cortinah/hockeystick

cran.r-project.org: hockeystick

Download and Visualize Essential Global Heating Data

  • Homepage: https://cortinah.github.io/hockeystick/
  • Documentation: http://cran.r-project.org/web/packages/hockeystick/hockeystick.pdf
  • Licenses: MIT + file LICENSE
  • Latest release: 1.0.0 (published 3 months ago)
  • Last Synced: 2026-11-28T23:00:29.279558Z (1 day ago)
  • Versions: 20
  • Dependent Packages: 0
  • Dependent Repositories: 1
  • Downloads: 772 Last month
  • Rankings:
    • Stargazers count: 7.113%
    • Forks count: 12.303%
    • Average: 18.62%
    • Downloads: 21.531%
    • Dependent repos count: 24.3%
    • Dependent packages count: 27.852%
  • Maintainers (1)

Dependencies

DESCRIPTION cran
  • R >= 4.0.0 depends
  • dplyr * imports
  • ggplot2 * imports
  • lubridate * imports
  • patchwork * imports
  • readr * imports
  • rvest * imports
  • scales * imports
  • tibble * imports
  • tidyr * imports
  • tools * imports
  • knitr * suggests
  • rmarkdown * suggests
  • spelling * suggests
  • viridisLite * suggests
.github/workflows/check-standard.yaml actions
  • actions/checkout v3 composite
  • r-lib/actions/check-r-package v2 composite
  • r-lib/actions/setup-pandoc v2 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/pkgdown.yaml actions
  • JamesIves/github-pages-deploy-action v4.4.1 composite
  • actions/checkout v3 composite
  • r-lib/actions/setup-pandoc v2 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite

Score: 11.422256498055392