https://github.com/boshek/rsoi
Import Climate Indices into R
https://github.com/boshek/rsoi
cran oceanic-nino oceanography r
Last synced: about 1 month ago
JSON representation
Import Climate Indices into R
- Host: GitHub
- URL: https://github.com/boshek/rsoi
- Owner: boshek
- Created: 2017-03-29T17:24:58.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2023-11-02T18:10:28.000Z (over 1 year ago)
- Last Synced: 2024-06-11T16:59:58.590Z (10 months ago)
- Topics: cran, oceanic-nino, oceanography, r
- Language: R
- Homepage: https://boshek.github.io/rsoi/
- Size: 980 KB
- Stars: 17
- Watchers: 2
- Forks: 5
- Open Issues: 3
-
Metadata Files:
- Readme: README.Rmd
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
- open-sustainable-technology - rsoi - An R package to download the most up to date climate indices. (Climate Change / Climate Data Access and Visualization)
README
---
output: github_document
---```{r, echo = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/",
warning = FALSE
)
```[](https://www.gnu.org/licenses/gpl-3.0)
[](https://github.com/boshek/rsoi/actions/workflows/R-CMD-check.yaml)[](https://cran.r-project.org/package=rsoi) [](https://CRAN.R-project.org/package=rsoi) [](https://cran.r-project.org/web/checks/check_results_rsoi.html)
# rsoi
An R package to download the most up to date of these climate indices:- Southern Oscillation Index
- Oceanic Nino Index
- North Pacific Gyre Oscillation
- North Atlantic Oscillation
- Arctic Oscillation
- Antarctic Oscillation
- Multivariate ENSO Index Version 2
- Pacific Decadal Oscillation
- Dipole Mode Index## Installation
For the development version```{r, eval = FALSE, echo = TRUE}
install.packages("rsoi")library(rsoi)
library(tibble)
``````{r, eval = TRUE, echo = FALSE}
library(rsoi)
library(tibble)
```## Usage
Download Oceanic Nino Index data
```{r, eval = TRUE, echo = TRUE, warning=FALSE, message=FALSE}
oni <- download_oni()
head(oni)
```And a quick plot to illustrate the data:
```{r plot, eval = TRUE, echo = TRUE, warning=FALSE, message=FALSE}
barcols <- c('#edf8b1','#7fcdbb','#2c7fb8')barplot(oni$ONI, names.arg = oni$Date, ylab = "Oceanic Nino Index" ,
col = barcols[oni$phase], border = NA, space = 0,
xaxt = "n")
```## Inspired by
The idea for this package borrows heavily from the `rpdo` package. `rsoi` now supercedes `rpdo` as a source of data in R for Pacific Decadal Oscillation.