generation: Simulate a Single Generation.

Description Usage Arguments Value

Description

This steps a population forwards by one generation, according to the parameters in a demography object, (which can also be passed in separately; see demography).

Usage

1
2
3
4
5
6
7
8
9
generation(population, demography, N = population$N,
  prob.seed = demography$prob.seed, fecundity = demography$fecundity,
  prob.germination = demography$prob.germination,
  prob.survival = demography$prob.survival,
  pollen.migration = demography$pollen.migration,
  seed.migration = demography$seed.migration,
  genotypes = demography$genotypes, mating = demography$mating,
  death.first = (is.null(demography$death.first) || demography$death.first),
  expected = FALSE, return.everything = FALSE, debug = FALSE, ...)

Arguments

population

A population object, the initial state of the population.

demography

A demography object, containing the below parameters.

N

Optionally, a matrix of the same form as population$N (overrides population$N if present).

prob.seed

Probability of producing seed, per individual.

fecundity

Mean number of seeds produced, per individual, if seeds are produced.

prob.germination

Probability of germination (establishment) per seed.

prob.survival

Probability of survival per already-extant individual.

pollen.migration

A migration object for pollen dispersal.

seed.migration

A migration object for seed dispersal.

genotypes

A character vector of genotypes.

mating

An array giving probabilities for offspring genotypes given parental genotypes.

death.first

If TRUE, germination probability is a function of densities *after* death has taken place.

expected

If TRUE, do no sampling, returning only expected values.

return.everything

If TRUE, returns the number of seeders, amount of pollen, density of seeds, number of germinating seeds, and number of dying individuals.

debug

Do checks for NAs and the like.

...

Additional parameters that will be passed to demographic functions.

Value

A matrix of the same dimensions as population$N, unless return.everything is TRUE, in which case it is a list with entries:

seeders : number of seeding individuals pollen : quantity of pollen produced, by genotype of parent seed.production : quantity of fertilized seeds produced seeds.dispersed : quantity of seeds, post-dispersal germination : number of new seeds that germinate (survive) death : number of previously alive individuals that die


petrelharp/landsim documentation built on May 25, 2019, 2:53 a.m.