knitr::opts_chunk$set( collapse = FALSE, comment = "#>", fig.path = "man/figures/README-", out.width = "100%" )
Tools for working with Global Historical Climatology Network (GHCN) data.
devtools::install_github("rwright88/ghcn")
Find a station based on a matching pattern:
library(ghcn) stations <- ghcn_find_stations(pattern = "new york") stations[1:6]
Read all daily data for one station, given the station ID:
dat <- ghcn_read(id = "USW00094728") str(dat[1:20])
Transform the data into an easier to use format, keeping only the five core statistics of daily precipitation, snow fall, snow depth, minimum temperature, and maximum temperature:
ghcn_clean(dat)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.