Learn R Programming

Rcapture (version 1.1)

robustd: Loglinear Models for Capture-Recapture Experiments Carried Out According to a Robust Design

Description

These functions compute various demographic parameters and capture probabilities per period using loglinear robust design models in capture-recapture experiments. robustd.t and robustd.0 fit the model on different response variable. robustd.t uses the frequencies of the observable capture histories in terms of capture success or failure for each capture occasions of each primary period (generated by histfreq.t). robustd.0 uses the frequencies of the observable capture histories in terms of number of captures per primary period (generated by histfreq.0).

Usage

robustd.t(X, dfreq = FALSE, vt, vm = "M0", vh = list("Chao"),
          va = 2, neg = TRUE)

robustd.0(X, dfreq = FALSE, vt, vm = "M0", vh = list("Chao"), 
          va = 2, neg = TRUE)

## S3 method for class 'robustd':
print(x, \dots)

Arguments

X
The table of the observed capture histories in one of the two accepted formats. In the default format, it has one row per unit captured in the experiment and sum(vt) columns. In the alternative format, it contains one row per capture history followed by i
dfreq
This argument specifies the format of the data matrix X. By default, it is set to FALSE, which means that X has one row per unit. If it is set to TRUE, then the matrix X contains frequencies in its last column.
vt
A vector containing the numbers of capture occasions for each primary sampling period. The length of this vector equals the number of primary sampling periods (noted $I$).
vm
A vector indicating the closed population model for each primary period. The elememts of vm can be "none"=no model, "M0"=M0 model, "Mt"=Mt model, "Mh"=Mh model or "Mth"=Mth model for robustd.t. For robustd.0, models
vh
A list indicating, for each primary period with a heterogeneity model, the form of the columns for heterogeneity in the design matrix. The elements of vht can be "Chao", "Poisson", "Darroch" or any numerical R function created be
va
A vector indicating, for each primary period with a Poisson heterogeneity model, the value of the exponent's base in $f(k)=a^k-1$. If va consists of a single number, this number is used for all the periods with a Poisson model. The default v
neg
If this option is set to TRUE, negative gamma parameters and negative eta parameters in Chao's models are set to zero. This insures that the estimated survival probabilities belong to [0, 1] and that the births are positive.
x
An object, produced by the robustd.t or the robustd.0 function, to print.
...
Further arguments passed to or from other methods.

Value

  • nThe number of captured units
  • modelsA vector of length $I$ identifying the closed population models chosen for each period.
  • model.fitA table containing the deviance, degrees of freedom and AIC of the fitted model.
  • emig.fitA table containing, for the model with an added temporary emigration effect, the deviance, degrees of freedom and AIC.
  • emig.paramThe estimated temporary emigration parameters and their standards errors. The $I-1$ first rows are estimations of the differences $logit(p^b)-logit(p^w)$ for periods 2 to $I-1$ ($p^b$ represents a between primary period and $p^w$ a within primary period estimate of the capture probability). The last row gives a pooled estimate of these differences calculated under the assumption that they are homogenous. Negative estimates are associated with a temporary emigration.
  • capture.probThe estimated capture probabilities per period and their standard errors.
  • survivalsThe estimated survival probabilities between periods and their standard errors.
  • NThe estimated population sizes per period and their standard errors.
  • birthThe estimated number of new arrivals in the population between periods and their standard errors.
  • NtotThe estimated total number of units who ever inhabited the survey area and its standard error.
  • loglin.paramThe loglinear model parameters estimations and their standard errors, calculated by the glm function.
  • u.vectorThe Ui statistics, useful for the survival probabilities calculation, and their standard errors
  • v.vectorThe Vi statistics, useful for the population sizes estimation, and their standard errors
  • covThe covariance matrix of all the demographic parameters estimates.
  • negThe position of the gamma and eta parameters set to zero in the loglinear parameter vector.

Details

These functions also generate statistics to test the presence of temporary emigration. The Poisson regression used to fit a robust design model has one entry for each possible caputre history, including those that are unobserved. The size of the dependent vector is therefore $2^{\mbox{sum(vn)}}-1$ for robustd.t. Models with a large sum(vt) are hard to fit with robustd.t. robustd.0 uses a more parsimonious coding for the capture histories and can fit larger models. Standard errors are calculated by linearization.

References

Baillargeon, S. and Rivest, L.P. (2007). Rcapture: Loglinear models for capture-recapture in R. Journal of Statistical Software, 19(5), http://www.jstatsoft.org/ Rivest, L.P. and Daigle, G. (2004) Loglinear models for the robust design in mark-recapture experiments. Biometrics, 60, 100--107.

See Also

closedp, openp

Examples

Run this code
data(mvole)

  # The mvole data set contains a total of 30 capture occasions (the 
  # tenth capture occasion doesn't have any new capture and is taken
  # out of the analysis). This number being large, we can only use 
  # the robustd.0 function to fit a robust design model.
robustd.0(mvole[,-10],vt=c(5,4,rep(5,4)),vm="Mh",vh="Poisson",va=1.5)
# Not run: 
# robustd.t(mvole[,-10],vt=c(5,4,rep(5,4)),vm="Mh",vh="Poisson",va=1.5)
# should fail

  # Considering only the first 3 periods of the data set, we can use the 
  # robustd.t function to fit a model with a temporal effect.
robustd.t(mvole[,c(1:9,11:15)],vt=c(5,4,5),vm="Mth",vh="Poisson",va=1.5)

Run the code above in your browser using DataLab