Simulate disease progress data under the monomolecular epidemic model, with optional replicated observations.
Arguments
- N
Total epidemic duration. Must be positive.
- dt
Time interval between assessments. Must be positive and less than or equal to `N`.
- y0
Initial disease intensity as a proportion, strictly between 0 and 1.
- r
Apparent infection rate. Must be positive.
- K
Maximum disease intensity as a proportion. Must be greater than or equal to `y0` and less than or equal to 1.
- n
Number of replicated curves. Must be a positive whole number.
- alpha
Non-negative noise level applied to replicated observations.
Examples
sim_monomolecular(N = 30, dt = 5, y0 = 0.01, r = 0.05, K = 1, n = 4)
#> replicates time y random_y
#> 1 1 0 0.0100000 0.01169094
#> 2 1 5 0.2289861 0.21922510
#> 3 1 10 0.3995322 0.38053801
#> 4 1 15 0.5323535 0.47643839
#> 5 1 20 0.6357949 0.66288295
#> 6 1 25 0.7163551 0.72894769
#> 7 1 30 0.7790955 0.78346656
#> 8 2 0 0.0100000 0.01000000
#> 9 2 5 0.2289861 0.25335197
#> 10 2 10 0.3995322 0.34527530
#> 11 2 15 0.5323535 0.45927077
#> 12 2 20 0.6357949 0.56806714
#> 13 2 25 0.7163551 0.67796910
#> 14 2 30 0.7790955 0.83748994
#> 15 3 0 0.0100000 0.01000000
#> 16 3 5 0.2289861 0.23366735
#> 17 3 10 0.3995322 0.41023495
#> 18 3 15 0.5323535 0.60265312
#> 19 3 20 0.6357949 0.62385272
#> 20 3 25 0.7163551 0.69773541
#> 21 3 30 0.7790955 0.78841827
#> 22 4 0 0.0100000 0.01000000
#> 23 4 5 0.2289861 0.24338948
#> 24 4 10 0.3995322 0.42415893
#> 25 4 15 0.5323535 0.54386353
#> 26 4 20 0.6357949 0.52763313
#> 27 4 25 0.7163551 0.70856899
#> 28 4 30 0.7790955 0.87037326
