vary_param.Rd
Generate a sequence of parameter values of length nstep
.
The user specify a number of "change points" in the sequence
the function fills out the rest of the sequence s.t.
the shape between each pair of consecutive change points is linear.
All values before the first element and after the last element in timing
are equal to the first element last element in vals
respectively.
vary_param(nstep, vals, timing)
nstep | The number of time steps to generate parameter values for, interpreted as the time range of the simulation. |
---|---|
vals | A vector of change point values in the sequence. |
timing | A vector of the indices specifying the location or step numbers at which the change points occur.
The length of |
A sequence of length nsteps.
#> [1] 2.50 2.50 2.95 3.40 2.67 1.93 1.20 1.20 1.20 1.20