predpreyLV: The Lotka-Volterra Predator-prey Model

Description Usage Arguments Value Author(s) References See Also Examples

Description

The Lotka-Volterra predator-prey model, for use with ode in the deSolve package.

Usage

1
predpreyLV(t, y, params)

Arguments

t

Argument for time

y

A vector of length 2, for population 1 and 2

params

Vector or list of parameters

Value

Returns a list of length one, for use with ode in the deSolve package.

Component 1

vector of the state variables, y.

Author(s)

Hank Stevens <HStevens@muohio.edu>

References

Lotka, A.J. (1956) Elements of Mathematical Biology. Dover Publications, Inc.

Stevens. M.H.H. (2009) A Primer of Ecology with R. Use R! Series. Springer.

See Also

predpreyRM

Examples

1
2
3
4
params1 <- c(b=.5, a=.01, s=.2, e=.1)
Time <- seq(0,100, by=.1) # Set time here
LV.out <- ode(c(H0=25,P0=5), Time, predpreyLV, params1)
matplot(Time, (LV.out[,2:3]), type="l", ylab="Population Size")

primer documentation built on Jan. 7, 2021, 1:07 a.m.