MC | R Documentation |
Function simulate given number of rainfall events with Latin Hypercube Monte-Carlo method. Correlations between rainfall parameters are taken into account by Iman-Conover method of simulating data.
MC(dt, rt = NULL, n = 1000)
dt |
data frame of sample of rainfall events |
rt |
numeric vector of length 2, lower and upper bound of rainfall event duration. See details |
n |
number of rainfall events to simulate |
You can choose bounds of rainfall event duration, which filter all events to particular type of rainfall (convectional, frontal or convergence zones)
return data frame of simulated rainfall parameters, number of simulated rows could be less than n
because function remove nonsensical simulations like t < 0 or P < 0
dt <- data.frame(P = rgamma(100, shape = 12, rate = 0.2), t = rlnorm(100, meanlog = 5, sdlog = 1)) MC(dt, rt = c(0,150), n = 1000)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.