Skip to content

Commit

Permalink
Merge pull request ReScience#16 from BIO6032/code_Fig3
Browse files Browse the repository at this point in the history
Fig. 3a) and 3b)
  • Loading branch information
tpoisot authored Mar 22, 2018
2 parents 56ad02c + 213149d commit 8361672
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion code/figure1.jl
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
using NamedTuples
using Plots

include("functions.jl")

# ...
# Simulation with specialist natural enemies with m=0.2
simulation1 = simulation(50.0, 25.0, m=0.2, F=4.0, D=0.5, c=1.0, a=0.5, th = 0.0)
# Fig 3a)
plot(simulation1[:,2:3], xlabel = "Generations",
labels = ["N", "P"],
ylims = (0, 50),
ylabel = "Populations")

# Simulation with specialist natural enemies with m=0.8
simulation2 = simulation(50.0, 25.0, m=0.8, F=4.0, D=0.5, c=1.0, a=0.5, th = 0.0)
# Fig 3b)
plot(simulation2[:,2:3], xlabel = "Generations",
labels = ["N", "P"],
ylims = (0, 50),
ylabel = "Populations")

0 comments on commit 8361672

Please sign in to comment.