Coder Social home page Coder Social logo

kvantas / hyetor Goto Github PK

View Code? Open in Web Editor NEW
6.0 2.0 0.0 697 KB

Analysis of fixed interval precipitation records

Home Page: https://kvantas.github.io/hyetor/

License: Other

R 93.66% TeX 6.34%
hydrology water-resources precipitation hydrometeorology meteorological-data tidy-data time-series r rstats r-package

hyetor's Introduction

hyetor

AppVeyor build status Travis build status Coverage status DOI CRAN status lifecycle

hyetor is an R package that provides a collection of tools that analyze fixed interval precipitation records. It can be used to:

  1. Aggregate precipitation values.
  2. Split precipitation time series to independent rainstorms using predefined monthly maximum dry period duration of no precipitation.
  3. Compile Unitless Cumulative Hyetographs.
  4. Find maximum rainfall intensities.
  5. Categorize rainstorms using Huff’s quartile classification.
  6. Calculate rainfall erosivity values using a number of energy equations.
  7. Create missing values summaries.

For more details checkout the package’s website and the vignettes:

Installation

You can install the development version from Github with:

# install.packages("devtools")
devtools::install_github("kvantas/hyetor")

Using hyetor

The functions that are provided by hyetor are:

  • Functions that can be used to preprocess precipitation time-series: hyet_create, hyet_fill, hyet_aggregate and hyet_split.
  • Functions that analyze precipitation time-series: hyet_erosivity, hyet_intensities, hyet_missing and hyet_uch.

The data sets that are provided by hyetor are:

  • prec5min, time series that comes from the weather station ‘Arna’ in Greece. The owner of that weather station is the Ministry of Environment and Energy. The time series period is from 12/1954 to 05/1956 and the time-step is 5 minutes.

Example

This is a minimal example which shows how to use the package’s functions to fill the internall precipitation timeseries, prec5min, and compute rainfall erosivity values.

library(hyetor)
library(ggplot2)
library(tibble)

ei_values <- prec5min %>%
  hyet_fill(time_step = 5, ts_unit = "mins") %>%
  hyet_erosivity(time_step = 5)

Let’s create a plot with erosivity values and total precipitation height.

ei_values %>%
  ggplot(aes(x = cum_prec, y = erosivity)) +
  geom_point() +
  geom_smooth(method = "loess") +
  scale_x_log10("Precipitation (mm)") +
  scale_y_log10("EI30 (MJ.mm/ha/h)") +
  theme_bw()

Meta

  • Bug reports, suggestions, and code are welcome. Please see Contributing.
  • Licence:
  • To cite hyetor please use:
Konstantinos Vantas, (2018). hyetor: R package to analyze fixed interval precipitation time  series, URL: https://kvantas.github.io/hyetor/,
DOI:http://doi.org/10.5281/zenodo.1403156

A BibTeX entry for LaTeX users is

@Manual{ vantas2018hyetor,
    author = {Konstantinos Vantas},
    title = {{hyetor}: R package  to analyze fixed interval precipitation time series},
    doi = {http://doi.org/10.5281/zenodo.1403156},
    year = {2018},
    note = {R package},
    url = {https://kvantas.github.io/hyetor/},
  }

hyetor's People

Contributors

kvantas avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

hyetor's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.