Run a model of competition for a biotic resource
run_biotic_comp_model.Rd
Run a model of competition for a biotic resource
Arguments
- time
vector of time units over which to run model, starting from 0.
time
can also be supplied as just the total length of the simulation (i.e. tmax)- init
vector of initial population sizes for both consumer species, with names P1 and P2, and resource species H
- params
vector of model parameters: c(r, q, a1, T_h1, e1, d1, a2, T_h2, e2, d2)
See also
plot_biotic_comp_time()
for plots of the population dynamics over
time
Examples
run_biotic_comp_model(
time = seq(0,10),
init = c(H = 30, P1 = 25, P2 = 25),
params = c(r = 0.2, q = .0066,
a1 = .02, T_h1 = 0.1, e1 = 0.4, d1 = 0.1,
a2 = .02, T_h2 = 0.1, e2 = 0.39, d2 = 0.1))
#> time H P1 P2
#> 1 0 30.0000000 25.00000 25.00000
#> 2 1 13.1451158 26.47904 26.37500
#> 3 2 5.6798241 25.68893 25.54344
#> 4 3 2.5795449 23.97608 23.82183
#> 5 4 1.2606052 22.01322 21.86362
#> 6 5 0.6659861 20.06620 19.92614
#> 7 6 0.3793953 18.23025 18.10118
#> 8 7 0.2318873 16.53475 16.41671
#> 9 8 0.1511992 14.98374 14.87621
#> 10 9 0.1045817 13.57150 13.47377
#> 11 10 0.0763259 12.28878 12.20007