fishStep2D: Two-dimensional fish time step

Description Usage Arguments Value Note See Also Examples

Description

Rate of change in planktivores and juvenile bass per time step

Usage

1
fishStep2D(X, pars = c(qE = 1), ...)

Arguments

X

length 2 named vector of state variables. Names are should be J0 (juveniles) and F0 (planktivores)

pars

a named vector of model parameters; in partiular, qE is harvest

...

Optional model parameters (e.g., see arguments in ecoStep), or other arguments to be passed to future methods.

Value

length-2 named vector (J0 and F0) indicating the rate of change per unit time in the abundances of juvenile bass (J0) and planktivores (F0).

Note

pars and ... are largely redundant. Their separation is merely for compatability with other functions, or for organizational purposes. The intended use is that parameters in pars correspond to parameters varied systematically to effect stability properties, whereas parameters specified through ... are being altered for exploration purposes, but would generally not be supplied because the defaults in ecoStep are suitable.

See Also

fishStep, ecoStep

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
# set up parameter, initials, roots
p <- c(qE=0.65) # harvest rate
state1 <- c(A0=1, F0=1, J0=1) # initial values
state2 <- c(A0=1E3, F0=1, J0=1E3) # alternate initials
r1 <- getRoot(state1, pars=p)[c("J0","F0")] # first root
r2 <- getRoot(state2, pars=p)[c("J0","F0")] # second root (alt stbl states)

# test dState/dt at root
fishStep2D(r1, pars=p) # 0 at lower root
fishStep2D(r2, pars=p) # 0 at upper root

# test dState/dt near, but not at, root
fishStep2D(r1+rnorm(2), pars=p) # non-0 away from root
fishStep2D(r2+rnorm(2), pars=p) # non-0 away from root

# test dState/dt at r1 and r2, but different qE
fishStep2D(r1) # qE defaults to 1; r1 ~0 for qE=1 & =0.65
fishStep2D(r2) # r2 ~0 for qE=0.65, not for qE=1

cboettig/bs-tipping documentation built on May 5, 2019, 7:08 a.m.