quant_gen: Quantitative genetics.

View source: R/quant_gen.R

quant_genR Documentation

Quantitative genetics.

Description

Quantitative genetics.

Usage

quant_gen(
  eta,
  d,
  q,
  n = 10,
  V0 = 1,
  N0 = rep(1, n),
  f = 0.1,
  a0 = 1e-04,
  r0 = 0.5,
  add_var = rep(0.01, n),
  sigma_V0 = 1,
  min_V0 = -1,
  max_V0 = -1,
  sigma_N = 0,
  sigma_V = 0,
  n_reps = 10,
  spp_gap_t = 500L,
  final_t = 5000L,
  min_N = 1,
  save_every = 10L,
  show_progress = TRUE,
  n_threads = 1
)

Arguments

eta

Number(s) representing the non-additive effects of traits on the growth rate. Should be a single number or a symmetrical, numeric, q by q matrix.

d

Number(s) that adjusts how the focal line is affected by other lines' trait values. Should be of length 1 or the same as the number of traits. If d < 0, then increases in V_j (trait that reduces competition experienced by clone j) increases competition experienced by clone i, thereby giving conflicting coevolution. Conversely, if d > 0, then increases in V_j decrease competition experienced by clone i, leading to nonconflicting coevolution.

V0

Trait value(s) for each starting clone. For only one starting line, must be a numeric vector or a single matrix row or column.

N0

Abundance(s) for each starting clone. Must be a numeric vector or a single matrix row or column.

f

A single number representing the cost of the trait on the growth rate.

a0

A single number representing the base density dependence.

r0

A single number representing the base growth rate.

add_var

Vector of additive genetic variances for all starting species.

sigma_V0

Standard deviation for normal distribution from which starting axis values can be derived. Set to 0 for species to start with the exact values of axes specified in V0. Set to negative number if you want to use a uniform distribution instead (see min_V0 and max_V0 below). Defaults to 1.

min_V0

Lower limit for uniform distribution that will generate starting axis values. Set to negative number if you want to use a normal distribution instead (see sigma_V0 above). Defaults to -1.

max_V0

Upper limit for uniform distribution that will generate starting axis values. Set to negative number if you want to use a normal distribution instead (see sigma_V0 above). Defaults to -1.

sigma_N

Standard deviation for stochasticity in population dynamics.

sigma_V

Standard deviation for stochasticity in axis evolution.

n_reps

Number of reps to perform.

spp_gap_t

Time period between each species introduction.

final_t

Length of final time period where all species are together.

min_N

Minimum N that's considered extant.

save_every

Number of time steps between when saving information for output.

show_progress

Boolean for whether to show a progress bar.

n_threads

Number of cores to use. Defaults to 1.

Value

A quant_gen object with nv (for N and V output) and call (for original call) fields.


lucasnell/evo_alt_states documentation built on Aug. 17, 2022, 5:34 a.m.