Description Usage Arguments Value References Examples
Generates seasonal time series using either the kNN Bootstrap (non-parametric) or a numerically-fitted PARMA(1,1) (parametric) model. For the parametric model, the function automatically transforms the seasonal sub-series to normal and deseasonalizes prior to model fitting.
1  | dirtyreps(Q, reps, years, k, d, adjust, parameters, method = "kNNboot")
 | 
Q | 
 time series object with seasonal resolution (e.g., frequency = 2, 3, 4, 6 or 12 for monthly data).  | 
reps | 
 integer. The number of replicates to be generated. The default is 100.  | 
years | 
 integer. The length of each replicate in years. The default is equal to the number of complete years given in Q.  | 
k | 
 integer. The k parameter of the kNN Bootstrap (i.e., number of nearest neighbors). If left blank k = n ^ 0.5., where n is the number of years in the input data.  | 
d | 
 integer. The d parameter of the kNN Bootstrap (i.e., number of previous time periods to inform the model). If left blank d = 1.  | 
adjust | 
 logical. If TRUE (the default) the final output time series X will be coerced for 0 <= X <= 1.2*max(Q). Applies only if the PARMA method is used.  | 
parameters | 
 logical. If TRUE the output will be given as a list including the replicate samples and relevant model parameters (k and d for kNNboot and phi, theta and standard deviation of residuals for PARMA). The default is FALSE.  | 
method | 
 character string giving the method used to generate the data. Defaults to "kNNboot" - the k Nearest Neighbour Bootstrap. See references for detail on the two methods available.  | 
Returns a multi time series object containing synthetic streamflow replicates.
kNN Bootstrap method: Lall, U. and Sharma, A., 1996. A nearest neighbor bootstrap for resampling hydrologic time series. Water Resources Research, 32(3), pp.679-693.
PARMA method: Salas, J.D. and Fernandez, B., 1993. Models for data generation in hydrology: univariate techniques. In Stochastic Hydrology and its Use in Water Resources Systems Simulation and Optimization (pp. 47-73). Springer Netherlands.
1 2 3 4 5  | 
[1] 154.7995
[1] 160.3558
[1] 165.9124
[1] 170.036
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.