LBRecap: Unconditional (complete) likelihood inference for...

Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/LBRecap.R

Description

Unconditional (complete) likelihood inference for a large class of discrete-time capture-recapture models under closed population with special emphasis on behavioural effect modelling including also the meaningful behavioral covariate approach proposed in Alunni Fegatelli (2013) [PhD thesis]. Many of the standard classical models such as M_0, M_b, M_{c_1}, M_t or M_{bt} can be regarded as particular instances of the aforementioned approach. Other flexible alternatives can be fitted through a careful choice of a meaningful behavioural covariate and a possible partition of its admissible range

Usage

1
2
3
4
5
6
7
LBRecap ( data,last.column.count = FALSE, neval = 1000, startadd=0, by.incr = 1,
mbc.function = c("standard","markov","counts","integer","counts.integer"),
mod = c("linear.logistic", "M0", "Mb", "Mc", "Mcb", "Mt", "Msubjective.cut",
        "Msubjective"), heterogeneity=FALSE, markov.ord=NULL, z.cut=c(),
         meaningful.mat.subjective = NULL, meaningful.mat.new.value.subjective = NULL,
         td.cov = NULL, td.cov.formula ="", verbose = FALSE, graph = FALSE,
         output = c( "base", "complete" ) )

Arguments

data

can be one of the following:

  1. an M by t binary matrix/data.frame. In this case the input is interpreted as a matrix whose rows contain individual capture histories for all M observed units

  2. a matrix/data.frame with (t+1) columns. The first t columns contain binary entries corresponding to capture occurrences, while the last column contains non negative integers corresponding to frequencies. This format is allowed only when last.column.count is set to TRUE

  3. a t-dimensional array or table representing the counts of the 2^t contingency table of binary outcomes

M is the number of units captured at least once and t is the number of capture occasions.

last.column.count

a logical. In the default case last.column.count=FALSE each row of the input argument data represents the complete capture history for each observed unit. When last.column.count is set to TRUE in each row the first t entries represent one of the observed complete capture histories and the last entry in the last column is the number of observed units with that capture history

neval

a positive integer. neval is the number of values of the population size N where the posterior is evaluated starting from M. The default value is neval=1000.

startadd

a positive integer. The likelihood evaluation is started from M+startadd that is from a value N which is strictly greater than the number of observed units. This can be useful when the likelihood has to be evaluated in a large range of N values and a reduced grid is called for.

by.incr

a positive integer. by.incr represents the increment on the sequence of possible population sizes N where the posterior is evaluated. The default value is by.incr=1. The use of by.incr>1 is discouraged unless the range of N values of interest is very large

mbc.function

a character string with possible entries (see Alunni Fegatelli (2013) for further details)

  1. "standard" meaningful behavioural covariate in [0,1] obtained through the normalized binary representation of integers relying upon partial capture history

  2. "markov" slight modification of "standard" providing consistency with arbitrary Markov order models when used in conjunction with the options "Msubjective" and z.cut.

  3. "counts" covariate in [0,1] obtained by normalizing the integer corresponding to the sum of binary entries i.e. the number of previous captures

  4. "integer" un-normalized integer corresponding to the binary entries of the partial capture history

  5. "counts.integer" un-normalized covariate obtained as the sum of binary entries i.e. the number of previous captures

mod

a character. mod represents the behavioural model considered for the analysis. mod="linear.logistic" is the model proposed in Alunni Fegatelli (2013) based on the meaningful behavioural covariate. mod="M0" is the most basic model where no effect is considered and all capture probabilities are the same. mod="Mb" is the classical behavioural model where the capture probability varies only once when first capture occurs. Hence it represents an enduring effect to capture. mod="Mc" is the ephemeral behavioural Markovian model originally introduced in Yang and Chao (2005) and subsequently extended in Farcomeni (2011) and reviewed in Alunni Fegatelli and Tardella (2012) where capture probability depends only on the capture status (captured or uncaptured) in the previous k=markov.ord occasions. mod="Mcb" is an extension of Yang and Chao's model (2005); it considers both ephemeral and enduring effect to capture. mod="Mt" is the standard temporal effect with no behavioural effect. mod="Msubjective.cut" is an alternative behavioural model obtained through a specific cut on the meaningful behavioural covariate interpreted as memory effect. mod="Msubjective" is a customizable (subjective) behavioural model within the linear logistic model framework requiring the specification of the two additional arguments: the first one is meaningful.mat.subjective and contains an M by t matrix of ad-hoc meaningful covariates depending on previous capture history; the second one is meaningful.mat.new.value.subjective and contains a vector of length t corresponding to meaningful covariates for a generic uncaptured unit. The default value for mod is "linear.logistic".

heterogeneity

a logical. If TRUE individual heterogeneity effect is considered in the model

markov.ord

a positive integer. markov.ord is the order of Markovian model M_c or M_{cb}. It is considered only if mod="Mc" or mod="Mcb".

z.cut

numeric vector. z.cut is a vector containing the cut point for the memory effect covariate. It is considered only if mod="Msubjective.cut"

meaningful.mat.subjective

M x t matrix containing numerical covariates to be used for a customized logistic model approach

meaningful.mat.new.value.subjective

1 x t numerical vector corresponding to auxiliary covariate to be considered for unobserved unit

td.cov

data frame or matrix with k columns and t rows with each column corresponding to a time-dependent covariate to be used at each capture occasion for any captured/uncaptured unit

td.cov.formula

a character string to be used as additional component in the glm/glmer formula. Names of each column of td.cov are forced to be X1, X2, ..... See examples when covariates have to be considered as factors.

verbose

a logical. If TRUE the percentage of likelihood evaluation is printed out while running.

graph

a logical. If TRUE a plot with the likelihood evaluations is sent to the graphical device. This helps to verify the possible presence of an almost flat profile likelihood for N

output

character. output select the kind of output from a very basic summary info on the posterior output (point and interval estimates for the unknown N) to more complete details including the estimates of the nuisance parameters and other features of the fitted model

Details

The LBRecap procedure is computing intensive for high values of neval.

Value

(if output="complete") the function LBRecap returns a list of:

  1. Modelmodel considered.

  2. N.hatunconditional maximum likelihood estimate for N

  3. CIinterval estimate for N

  4. AICAkaike information criterion.

  5. L.FailureLikelihood Failure condition

  6. N.rangevalues of N considered.

  7. log.likvalues of the log-likelihood distribution for each N considered

  8. z.matrixmeaningful behavioural covariate matrix for the observed data

  9. vec.cutcut point used to set up meaningful partitions the set of the partial capture histories according to the value of the value of the meaningful behavioural covariate.

Author(s)

Danilo Alunni Fegatelli and Luca Tardella

References

Alunni Fegatelli, D. and Tardella, L. (2016), Flexible behavioral capture–recapture modeling. Biometrics, 72(1):125-135. doi:10.1111/biom.12417

Alunni Fegatelli D. (2013) New methods for capture-recapture modelling with behavioural response and individual heterogeneity. http://hdl.handle.net/11573/918752

Alunni Fegatelli, D. and Tardella, L. (2012) Improved inference on capture recapture models with behavioural effects. Statistical Methods & Applications Applications Volume 22, Issue 1, pp 45-66 10.1007/s10260-012-0221-4

Farcomeni A. (2011) Recapture models under equality constraints for the conditional capture probabilities. Biometrika 98(1):237–242

See Also

LBRecap.custom.part, LBRecap.all, BBRecap

Examples

1
2
3
data(greatcopper)
mod.Mb=LBRecap(greatcopper,mod="Mb")
str(mod.Mb)

BBRecapture documentation built on March 26, 2020, 7:31 p.m.