countHist {AICcmodavg} R Documentation

## Compute Summary Statistics from Count Histories

### Description

This function extracts various summary statistics from count data of various unmarkedFrame and unmarkedFit classes.

### Usage

countHist(object, plot.freq = TRUE, cex.axis = 1, cex.lab = 1,
cex.main = 1, ...)

## S3 method for class 'unmarkedFramePCount'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1, ...)

## S3 method for class 'unmarkedFitPCount'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1, ...)

## S3 method for class 'unmarkedFrameGPC'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1, ...)

## S3 method for class 'unmarkedFitGPC'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1, ...)

## S3 method for class 'unmarkedFrameMPois'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1, ...)

## S3 method for class 'unmarkedFitMPois'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1, ...)

## S3 method for class 'unmarkedFramePCO'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1,
plot.seasons = FALSE, ...)

## S3 method for class 'unmarkedFitPCO'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1,
plot.seasons = FALSE, ...)

## S3 method for class 'unmarkedFrameGMM'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1,
plot.seasons = FALSE, ...)

## S3 method for class 'unmarkedFitGMM'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1,
plot.seasons = FALSE, ...)

## S3 method for class 'unmarkedFrameMMO'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1,
plot.seasons = FALSE, ...)

## S3 method for class 'unmarkedFitMMO'
countHist(object, plot.freq = TRUE,
cex.axis = 1, cex.lab = 1, cex.main = 1,
plot.seasons = FALSE, ...)



### Arguments

 object an object of various unmarkedFrame or unmarkedFit classes containing count history data. plot.freq logical. Specifies if the count data (pooled across seasons) should be plotted. cex.axis expansion factor influencing the size of axis annotations on plots produced by the function. cex.lab expansion factor influencing the size of axis labels on plots produced by the function. cex.main expansion factor influencing the size of the main title above plots produced by the function. plot.seasons logical. Specifies if the count data should be plotted for each season separately. This argument is only relevant for data collected across more than a single season. ... additional arguments passed to the function.

### Details

This function computes a number of summary statistics in data sets used for various N-mixture models including those of Royle (2004a, b), Dail and Madsen (2011), and Chandler et al. (2011).

countHist can take data frames of the unmarkedFramePCount, unmarkedFrameGPC, unmarkedFrameMPois, unmarkedFramePCO, unmarkedFrameGMM, unmarkedFrameMMO classes as input. For convenience, the function can also extract the raw data from model objects of classes unmarkedFitPCount, unmarkedFitGPC, unmarkedFitMPois, unmarkedFitPCO, unmarkedFitGMM, and unmarkedFitMMO. Note that different model objects using the same data set will have identical values.

### Value

countHist returns a list with the following components:

 count.table.full a table with the frequency of each observed count. count.table.seasons a list of tables with the frequency of each season-specific count. hist.table.full a table with the frequency of each count history across the entire sampling period. hist.table.seasons a list of tables with the frequency of each count history for each primary period (season). out.freqs a matrix where the rows correspond to each sampling season and where columns consist of the number of sites sampled in season t (sampled) and the number of sites with at least one detection in season t (detected). For multiseason data, the matrix includes the number of sites sampled in season t - 1 with colonizations observed in season t (colonized), the number of sites sampled in season t - 1 with extinctions observed in season t (extinct), the number of sites sampled in season t - 1 without changes observed in season t (static), and the number of sites sampled in season t that were also sampled in season t - 1 (common). out.props a matrix where the rows correspond to each sampling season and where columns consist of the proportion of sites in season t with at least one detection (naive.occ). For multiseason data, the matrix includes the proportion of sites sampled in season t - 1 with colonizations observed in season t (naive.colonization), the proportion of sites sampled in season t - 1 with extinctions observed in season t (naive.extinction), and the proportion of sites sampled in season t - 1 with no changes observed in season t. n.seasons the number of seasons (primary periods) in the data set. n.visits.season the maximum number of visits per season in the data set. missing.seasons logical vector indicating whether data were collected or not during a given season (primary period), where TRUE indicates that no data were collected during the season.

### Author(s)

Marc J. Mazerolle

### References

Chandler, R. B., Royle, J. A., King, D. I. (2011) Inference about density and temporary emigration in unmarked populations. Ecology 92, 1429–1435.

Dail, D., Madsen, L. (2011) Models for estimating abundance from repeated counts of an open population. Biometrics 67, 577–587.

Royle, J. A. (2004a) N-mixture models for estimating population size from spatially replicated counts. Biometrics 60, 108–115.

Royle, J. A. (2004b) Generalized estimators of avian abundance from count survey data. Animal Biodiversity and Conservation 27, 375–386.

covDiag, detHist, detTime, countDist, Nmix.chisq, Nmix.gof.test

### Examples

##modified example from ?pcount
## Not run:
if(require(unmarked)){
data(mallard)
mallardUMF <- unmarkedFramePCount(mallard.y, siteCovs = mallard.site,
obsCovs = mallard.obs)
##compute descriptive stats from data object
countHist(mallardUMF)

##run single season model
fm.mallard <- pcount(~ ivel+ date + I(date^2) ~ length + elev +
forest, mallardUMF, K=30)
##compute descriptive stats from model object
countHist(fm.mallard)
}

## End(Not run)


[Package AICcmodavg version 2.3-3 Index]