lineage_generation: Simulate a Single Backwards Generation

Description Usage Arguments Value

Description

Given a collection of lineages, all of the same genotype, sample from their location in the previous generation, given the entire set of reproductive numbers in that generation.

Usage

1
lineage_generation(lineages, N, gen, num.alleles, demog, debug = FALSE)

Arguments

lineages

A two-column matrix with columns labeled 'location' and 'genotype'.

N

The population state at the start of the previous generation.

gen

A list as returned by generation(...,return.everything=TRUE).

num.alleles

A vector giving the number of alleles of the type followed in each genotype.

demog

The demography object that contains migration matrices used to make the simulation.

debug

Whether to run sanity checks.

Value

A matrix of the same form as lineages.


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