First a series, say \(x\), of random numbers is generated as
requested by the argument f. Then, if shift and/or
scale are supplied, the values are modified as follows:
$$y_t = shift_{k} + scale_{k} x_t$$
where \(k\) is the season corresponding to time \(t\).
The vector \(y\) is returned.
If f is a single a function (or name of a function), then the
series is generated (effectively) by the call f(n,...).
The argument f may also be a list whose \(k\)th element
is itself a list specifying the random number generator for the
\(k\)th season. The first element being the function (such as
rnorm) and the remaining elements being parameters for that
function. Parameters common to all seasons may be supplied through
the ... argument.
The argument period may be omitted. In that case it is inferred
from f and/or the lengths of shift and
scale. Currently there is no check for consistency here.
The arguments shift and scale may be used to specify
simple linear transformations of the generated values, possibly
different for the different seasons. Each of them should be a vector
of length period or one.
seasonof1st can be used to request the simulated time series to
start from a season other than the first one. Note that whatever the
value of seasonof1st, the first elements of scale,
shift and f (if a list) are taken to refer to season
one.