Simple constant runoff proportion: a constant fraction of rainfall reaches the stream.

scalar.sim(DATA, scale, return_state = FALSE)

Arguments

DATA

time-series-like object with a column P (precipitation).

scale

fraction of rainfall that becomes effective. If this parameter is set to NA (as it is by default) in hydromad it will be set by mass balance calculation.

return_state

ignored.

Value

the simulated effective rainfall, a time series of the same length as the input series.

See also

hydromad(sma = "scalar") to work with models as objects (recommended).

Author

Felix Andrews felix@nfrac.org

Examples


## view default parameter ranges:
str(hydromad.options("scalar"))
#> List of 1
#>  $ scalar:List of 1
#>   ..$ scale: num NA

data(HydroTestData)
mod0 <- hydromad(HydroTestData, sma = "scalar", routing = "expuh")
mod0
#> 
#> Hydromad model with "scalar" SMA and "expuh" routing:
#> Start = 2000-01-01, End = 2000-03-31
#> 
#> SMA Parameters:
#>  scale  
#> 0.6534  
#> Routing Parameters:
#> NULL

## simulate with some arbitrary parameter values
testQ <- predict(update(mod0, scale = 0.5, tau_s = 10))
xyplot(cbind(HydroTestData[, 1:2], scalar.Q = testQ))