Skip to contents

Conversion of meteorological data from sub-basin scale to basin scale

Usage

convertMeteoBVI2BV(x, ...)

# S3 method for data.frame
convertMeteoBVI2BV(x, griwrm, ...)

# S3 method for GRiwrm
convertMeteoBVI2BV(x, meteo, ...)

# S3 method for character
convertMeteoBVI2BV(x, griwrm, meteo, ...)

# S3 method for matrix
convertMeteoBVI2BV(x, areas, temperature = FALSE, ...)

Arguments

x

either a GRiwrm network description (See CreateGRiwrm), a character id of a node, or a matrix or a data.frame containing meteorological data (See details)

...

Parameters passed to the methods

griwrm

GRiwrm object describing the semi-distributed network (See CreateGRiwrm)

meteo

matrix or data.frame containing meteorological data. Its colnames should be equal to the ID of the basins

areas

numeric vector with the total area of the basin followed by the areas of the upstream basins in km2

temperature

logical TRUE if the meteorological data contain air temperature. If FALSE minimum output values are bounded to zero

Value

matrix a matrix containing the converted meteorological data or a data.frame if x is a data.frame.

Details

If x is a data.frame, the first column should a POSIXct containing the date and the other columns the time series data.