Description Usage Arguments Details Value References Examples
Given output from the killSome function, randomly settles individuals in the arena.
1 | settleSome(killSome.output)
|
killSome.output |
Output from the killSome function |
This function uses the number killed element of the killSome output to randomly draw from the regional abundance vector, then settles the individuals at random in the arena.
A list of 4 elements: the average relatedness in the geographic neighbordhood of consideration (passed directly from the killSome output, not re-calculated here), the regional abundance vector, the new spatial arena, and the dimensions of that arena.
Miller, E. T., D. R. Farine, and C. H. Trisos. 2016. Phylogenetic community structure metrics and null models: a review with new methods and software. Ecography DOI: 10.1111/ecog.02070
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | #simulate tree with birth-death process
tree <- geiger::sim.bdtree(b=0.1, d=0, stop="taxa", n=50)
#prep the data for the simulation
prepped <- prepSimulations(tree, arena.length=300, mean.log.individuals=2,
length.parameter=5000, sd.parameter=50, max.distance=20, proportion.killed=0.2,
competition.iterations=5)
#use the competition simulation
positions <- competitionArena(prepped)
#in normal use, these parameters will be carried down from the simulations.input object
new.arena <- killSome(tree, arena.output=positions, max.distance=50,
proportion.killed=0.2)
#now settle some indiviudals
newer.arena <- settleSome(new.arena)
#look at how number of individuals in arena changes
dim(new.arena$arena)
dim(newer.arena$arena)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.