reduce.traps --
Grouping may be specified explicitly via newtraps
, or
implicitly by span
.
If span
is specified a clustering of detector sites will be
performed with hclust
and detectors will be assigned to
groups with cutree
. The default algorithm in hclust
is complete linkage, which tends to yield compact, circular clusters;
each will have diameter less than or equal to span
.
reduce.capthist --
The first component of newoccasions
defines the columns of
object
for new occasion 1, the second for new occasion 2, etc. If
newoccasions
is NULL then all occasions are output. Subscripts in a
component of newoccasions
that do not match an occasion in the input
are ignored. When the output detector is one of the trap types
(`single', `multi'), reducing capture occasions can result in locational
ambiguity for individuals caught on more than one occasion, and for
single-catch traps there may also be conflicts between individuals at
the same trap. The method for resolving conflicts among `multi'
detectors is determined by select
which should be one of `first',
`last' or `random'. With `single' detectors select
is ignored and
the method is: first, randomly select* one trap per animal per day;
second, randomly select* one animal per trap per day; third, when
collapsing multiple days use the first capture, if any, in each
trap.
Usage data in the traps
attribute are also pooled if present;
usage is summed over contributing occasions and detectors. If there is
no 'usage' attribute in the input, and outputdetector
is one of
'count', 'polygon', 'transect' and 'telemetry', a homogeneous (all-1's)
'usage' attribute is first generated for the input.
* i.e., in the case of a single capture, use that capture; in the case of
multiple `competing' captures draw one at random.
If newoccasions
is not provided then old occasions are grouped into
new occasions as indicated by the by
argument. For example, if
there are 15 old occasions and by = 5
then new occasions will be
formed from occasions 1:5, 6:10, and 11:15. A warning is given when the
number of old occasions is not a multiple of by
as then the final
new occasion will comprise fewer old occasions.
dropunused = TRUE
has the possibly unintended effect of dropping
whole occasions on which there were no detections.
A special use of the by
argument is to combine all occasions into
one for each session in a multi-session dataset. This is done by setting
by = "all"
.