mean.river.mom: Calculates mean values from MOM river input data

Description Usage Arguments Value Author(s) See Also Examples

View source: R/mean.river.mom.R

Description

Calculates mean values from river inflow data. Currently, only averaging from monthly to annual means is implemented.

Usage

1
2
## S3 method for class 'river.mom'
mean(inData, from = inData$tstep, to = "none")

Arguments

inData

list containing a data.frame (in$data) with river inflow data, a character array (in$units) with corresponding units, and two character variables (in$format and in$tstep).

from

character: current data averaging interval; does not need to be set if in$tstep is set properly; if not, it can be manually set to e.g. 'annual', 'monthly', or 'daily'

to

character: future averaging interval; e.g. 'annual', 'monthly', or 'daily'

Value

list of newly averaged data; same structure as input data;

list containing a data.frame (out$data), a character array (out$units), and two character variables (out$format and out$tstep). The first contains the actual data formatted as a data.frame. The second contains the units to the corresponding columns of the data.frame. The third contains the source/format of data (here: 'mom'; can also be 'swat'). The fourth contains information on the time step of the data (resp.: on which time interval they are averaged).

Author(s)

Daniel Neumann, daniel.neumann@io-warnemuende.de

See Also

read.river.mom, write.river.append2NML, write.river.newNML, interpolate.river.mom

Examples

1
2
3
4
5
6
  # read a file:
  test.mom.monthly <- read.river.mom('files/GER_Dan_Str_Warnow.dat')
  
  # calculate annual means from monthly data
  test.mom.annual <- mean.river.mom(test.mom.monthly, to = 'annual')
  

neumannd/riverdata documentation built on March 4, 2020, 4:22 a.m.