run_source_sink: Simulate dynamics of the source and sink populations under...

View source: R/source_sink_dynamics.R

run_source_sinkR Documentation

Simulate dynamics of the source and sink populations under Pulliam (1988)'s model

Description

Simulate dynamics of the source and sink populations under Pulliam (1988)'s model

Usage

run_source_sink(endtime, init, params)

Arguments

endtime

a number to indicate at what timesetp to end the simulation

init

a vector of initial population sizes of the source and sink population

params

a vector of model parameters

See Also

plot_source_sink() for plotting the size of the source and sink population over time

Examples

# in this example, source and sink population start at the same size,
# the sink population dies out, but is later replenished by immigration
# from the source patch once all source breeding sites are occupied
run_source_sink(endtime = 50, init = c(n0Source = 100, n0Sink = 100),
params = c(pa = 0.6, pj = 0.15, betaSource = 3, betaSink = 1, NSource = 300))

gauravsk/ecoevoapps documentation built on July 9, 2024, 9:37 p.m.