reduce.capthist {secr} | R Documentation

## Combine Occasions

### Description

Combine columns (occasions) in a `capthist` object to create a new data set. Where the input data allow only one observation per occasion (detector types 'single' and 'multi') the pooled data may optionally be treated as if from a 'proximity' detector (i.e. multiple observations per individual per occasion).

### Usage

    ## S3 method for class 'capthist':
    reduce(object, columns, ..., outputdetector = NULL, random = TRUE)

### Arguments

`object` | `capthist` object
`columns` | list in which each component is a vector of subscripts for occasions to be pooled
`...` | other arguments (not used currently)
`outputdetector` | character value giving detector type for output
`random` | logical for resolution of conflicts

### Details

The first component of `columns` defines the columns of `object` for new occasion 1, the second for new occasion 2, etc. Ambiguity is possible in the pooled data; this is resolved by retaining only the first detection on any pooled (new) occasion (or a random selection if `random` = TRUE). Usage data in the `traps` attribute are also pooled if present; a trap is considered 'used' on a pooled occasion if it was used on any contributing occasion. `outputdetector` defaults to the detector type of the input.

With trap detectors, reducing capture occasions can result in locational ambiguity for individuals caught more than one occasion. By default, these are resolved by choosing one location at random; otherwise (random = FALSE) the first is used. `outputdetector` = 'single' is not allowed because of the large potential for conflicts.

### Value

An object of class `capthist` with number of columns equal to `length(occasions)`. The detector type is inherited from `x` unless a new type is specified with the argument `outputdetector`.

### Author(s)

Murray Efford murray.efford@otago.ac.nz

### See Also

`capthist`, `subset.capthist`

### Examples

    tempcapt <- sim.capthist (make.grid(nx = 6, ny = 6), nocc = 6)
    class(tempcapt)

    pooled.tempcapt <- reduce(tempcapt, col = list(1,2:3,4:6))
    summary (pooled.tempcapt)

[Package secr version 1.2.11 Index]