Scaling Exponent Response, assuming replacement
Description
Scaling exponent response (assuming replacement) based on ideas dating back to Real (1977, at least)
Usage
1 2 3 4 
Arguments
data 
A dataframe containing X and Y. 
samp 
A vector specifying the rows of data to use in the fit. Provided by 
start 
A named list. Starting values for items to be optimised. Usually 'a' and 'h'. 
fixed 
A names list. 'Fixed data' (not optimised). Usually 'T'. 
boot 
A logical. Is the function being called for use by 
windows 
A logical. Is the operating system Microsoft Windows? 
b, q, h 
The search coefficient (b), scaling exponent (q) and the handling time (h). Usually items to be optimised. 
T 
T, the total time available. 
X 
The X variable. Usually prey density. 
Y 
The Y variable. Usually the number of prey consumed. 
Details
This implements a typeII response with a scaling exponent on the capture rate (a), based on the use of Hill's exponents described by Real (1977). When q ≥ 0 the response becomes progressively more 'typeIIIish'. Integer values of q have useful interpretations based in enzymatic biochemistry but have been extended to many other fields (e.g. Flynn et al. 1997), including functional response analysis (VucicPestic et al. 2010). Importantly, this function assumes that prey are replaced throughout the experiment (c.f. flexpnr
which does not).
The capture rate (a) follows the following relationship:
a = b*X^q
and then (a) is used to calculate the number of prey eaten (Ne) following the same relationship as hollingsII
:
Ne=(a*N0*T)/(1+a*N0*h)
where b is a search coefficient and other coefficients are as defined in hollingsII
. Indeed when q = 0, then a = b and the relationship collapses to traditional typeII Holling's Disc Equation. There is, therefore, a useful test on q = 0 in the summary of the fit.
None of these functions are designed to be called directly, though they are all exported so that the user can call them directly if desired. The intention is that they are called via frair_fit
, which calls them in the order they are specified above.
flexp_fit
does the heavy lifting and also pulls double duty as the statistic
function for bootstrapping (via boot()
in the boot package). The windows
argument if required to prevent needless calls to require(frair)
on platforms that can manage sane parallel processing.
The core fitting is done by mle2
from the bbmle
package and users are directed there for more information. mle2
uses the flexp_nll
function to optimise flexp
.
Further references and recommended reading can be found on the help page for frair_fit.
Author(s)
Daniel Pritchard
References
Real LA (1977) The Kinetics of Functional Response. The American Naturalist 111: 289–300.
VucicPestic O, Rall BC, Kalinkat G, Brose U (2010) Allometric functional response model: body masses constrain interaction strengths. Journal of Animal Ecology 79: 249–256. doi:10.1111/j.13652656.2009.01622.x.
Flynn KJ, Fasham MJR, Hipkin CR (1997) Modelling the interactions between ammonium and nitrate uptake in marine phytoplankton. Philosophical Transactions of the Royal Society B: Biological Sciences 352: 1625–1645.
See Also
frair_fit
, flexpnr
.
Examples
1 2 3 4 5 6 7 8 9 10 11 12  data(bythotrephes)
# NB: The flexpnr model is not correct for the experimental design of the bythotrephes data
expofit < frair_fit(eaten~density, data=bythotrephes,
response='flexpnr', start=list(b = 0.5, q = 1, h = 0.15),
fixed=list(T=1))
## Plot
plot(expofit)
lines(expofit, col=2)
## Inspect
summary(expofit$fit)
