secr.fit
. A
simple SECR model is fitted by a fast ad hoc method.autoini(capthist, mask, detectfn = 0, thin = 0.2, tol = 0.001,
binomN = 1, adjustg0 = TRUE, ignoreusage = FALSE)
capthist
objectmask
object compatible with the detector layout in
capthist
secr.fit
)traps(capthist)
autoini
; other initial values can usually be set to
zero for secr.fit
. If the algorithm encounters problems obtaining
a value for g0, the default value of 0.1 is returned.
Only the halfnormal detection function is currently available in autoini
(cf
other options in e.g. detectfn and sim.capthist
).
autoini
implements a modified version of the algorithm proposed
by Efford et al. (2004). In outline, the algorithm is
RPSV
)esa
)uniroot
.
If RPSV
cannot be computed the algorithm tries to use observed
mean recapture distance $\bar{d}$. Computation of
$\bar{d}$ fails if there no recaptures, and all returned
values are NA.
If the mask has more than 100 points then a proportion 1--thin
of
points are discarded at random to speed execution.
The argument tol
is passed to uniroot
. It may be a
vector of two values, the first for g0 and the second for sigma.
If traps(capthist)
has a usage attribute (defining effort
on each occasion at each detector) then the value of g0 is divided by
the mean of the non-zero elements of usage. This adjustment is not
precise.
If adjustg0
is TRUE then an adjustment is made to g0 depending
on the value of binomN
. For Poisson counts (binomN = 0
)
the adjustment is linear on effort (adjusted.g0 = g0 /
usage). Otherwise, the adjustment is on the hazard scale (adjusted.g0 =
1 -- (1 -- g0) ^ (1 / (usage x binomN))). An arithmetic average is taken
over all non-zero usage values (i.e. over used detectors and times). If
usage is not specified it is taken to be 1.0.capthist
, mask
, secr.fit
, dbar
demotraps <- make.grid()
demomask <- make.mask(demotraps)
demoCH <- sim.capthist (demotraps, popn = list(D = 5, buffer = 100))
autoini (demoCH, demomask)
Run the code above in your browser using DataLab