get_endpoint: Predict evolutionary endpoint

View source: R/get_endpoint.R

get_endpointR Documentation

Predict evolutionary endpoint

Description

Predicts the evolutionary equilibrium reached given a starting point and some parameter values, and if this equilibrium is stable.

Usage

get_endpoint(
  xstart,
  pars,
  init,
  from = xstart - 10,
  to = xstart + 10,
  step = 1e-04,
  ...
)

Arguments

xstart

The starting resident trait value

pars

An unevaluated parameter-list (e.g. as returned by get_default_pars)

init

A vector of two starting values for solving of the demographic equilibrium

from, to

Arguments to be passed to find_singularities (only the bound towards which the initial selection gradient is pointing is considered)

step

Argument to be passed to is_convergent

...

Optional extra arguments for find_singularities

Details

The function computes the selection gradient at the starting point to know in which direction evolution is leading, then finds the closest singularity in that direction.

Value

A data frame with the singularity, whether it is attainable and whether it is evolutionarily stable. If a singularity is attainable and stable, it is an evolutionarily stable strategy (labelled "ESS"). If it is attainable and unstable, it is a branching point ("BP"). If it is unattainable, it is a repeller.

See Also

get_gradient, find_singularities, is_stable, is_convergent

Examples


pars <- get_default_pars()
get_endpoint(0, pars, init = rep(1000, 2))


rscherrer/speciomx documentation built on March 28, 2023, 8:49 p.m.