Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/martinschobben/timemachine
Educational app for understanding past, current and future climate change
https://github.com/martinschobben/timemachine
climate climate-change
Last synced: about 1 month ago
JSON representation
Educational app for understanding past, current and future climate change
- Host: GitHub
- URL: https://github.com/martinschobben/timemachine
- Owner: MartinSchobben
- License: gpl-3.0
- Created: 2020-11-17T12:21:19.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2020-12-06T07:23:15.000Z (about 4 years ago)
- Last Synced: 2024-01-29T17:12:34.469Z (11 months ago)
- Topics: climate, climate-change
- Language: R
- Homepage:
- Size: 657 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.Rmd
- License: LICENSE.md
Awesome Lists containing this project
README
---
output:
github_document:
pandoc_args: --webtex=http://chart.apis.google.com/chart?cht=tx&chl=
bibliography: /home/amandus/Documents/work/library/biblio.bib
---```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%",
warning = FALSE,
results = "asis",
encoding ='UTF-8'
)
```# Introduction to the timemachine app
This app is intended for educational purposes. The interactive plots should instill a better appreciation of long geological timescales and our current understanding of past, present and future climate. The current rate of climate change is unprecedented when compared to what we know of past climate and extreme climate events, such as the Paleocene-Eocene Thermal Maximum (PETM; ~56 Ma).
I am still developing the app.
# Data sources and compilation
The surface temperature record spanning the Cretaceous up to the Holocene is based on the corrected $\delta$^18^O dataset of @Westerhold2020, and following the same corrections for the presence of ice as described in @Hansen2013. The Holocene temperatures are based on the global temperature anomaly (Standard~5x5Grid~) stack of @Marcott2013 spliced on top of a 1961--1990 mean temperature of 14$\,$°C [@Hansen2013]. The instrumental HadCrut4 sea surface anomaly dataset was downloaded from the Climatic Research Unit (University of East Anglia) and Met Office [website](https://crudata.uea.ac.uk/cru/data/temperature/HadSST3-gl.dat). This record was spliced on top of the mean temperature of the @Marcott2013 record for the interval between 1961 and 1990. Future extrapolations (scenarios or Representative
Concentration Pathways) are based on the General Circulation Model data generated by the BCC_CM1 model, which was downloaded from the [Climate4impact](https://climate4impact.eu/) website. The composite dataset of the app can be recompiled by running the scripts contained in the data-raw directory. The function `read_instrum_data()` will generate a global average value for the instrumental HadCrut4 data, see also the website above for the same code. The script `reduce_clim_model.R` can be used to flatten the array of time-incremented model data spanning up 2100.```{r pkgs, echo = FALSE, warnings = FALSE, message=FALSE}
refs <- miscutils::pkg_refworker(
c("shiny", "Cairo", "ggplot2", "gtable", "dplyr", "tibble", "tidyr", "rlang",
"gridExtra", "devtools", "roxygen2", "testthat", "knitr", "rmarkdown",
"Cairo"
),
"library.bib",
"biblio.bib"
)```
# Basic usage of the R package## Installation
You can install the released version of timemachine and run the app from your
local console.``` r
# Install timemachine from GitHub:
# install.packages("devtools")
devtools::install_github("MartinSchobben/timemachine")
```## Usage
Load point with `library`.
```r
library(timemachine)
```
## Run the appStart the app by running.
```r
timemachine_app()
```# Credits
The *timemachine* app is created with *shiny*[@shiny] in the R language[@rversion]. The package and app rely on a set of external packages from the tidyverse universe, including: *dplyr* [@dplyr], *tidyr* [@tidyr], *tibble* [@tibble], *ggplot2* [@ggplot2], *rlang* [@rlang]. Package development is aided by; *devtools* [@devtools], *roxygen2* [@roxygen2], *testthat* [@testthat]. This README file is generated with *knitr* [@knitr1 ; @knitr2], *rmarkdown* [@rmarkdown1; @rmarkdown2]. The graphics for the chronostratigraphic plots use the packages; *gridExtra* [@gridExtra], *gtable* [@gtable], and *Cairo* [@Cairo].
The book: *Mastering Shiny*, by @Wickham2020 greatly helped development of the app.
# References