checkallmodels: Check all possible models

Description Usage Arguments Details Value Examples

Description

This routine checks every possible model for existence and identifiability of the maximum likelihood estimates.

Usage

1
checkallmodels(zdata, verbose = F)

Arguments

zdata

Data matrix with t+1 columns. The first t columns, each corresponding to a particular list, are 0s and 1s defining the capture histories observed. The last column is the count of cases with that particular capture history. List names A, B, ... are constructed if not supplied. Where a capture history is not explicitly listed, it is assumed that it has observed count zero.

verbose

Specifies whether all possible models are listed in the output, or only those which generate a non-zero error code.

Details

The routine calls the routine checkident for every model. If there are t lists then there are t(t-1)/2 pairs of lists, and hence 2^{t(t-1)/2} possible models, because the models correspond to subsets of the set of all pairs of lists. If t = 7 there are 2,097,152 models to check, which would take several hours. If t is equal to 8 or more, the routine terminates with a statement of the number of models and an explanation that checking all of these is not possible in a reasonable time.

Value

If verbose=F, it gives a matrix each of whose rows specifies a model, with last entry equal to the error code. Only those models yielding a non-zero error code are included, so if no models lead to an error the matrix is empty. Each of the first t(t-1)/2 columns corresponds to a pair of lists, and for each row, presence in or absence from the corresponding model is indicated by the value 1 or 0 respectively.

If verbose=T, it gives the full matrix of models together with the error codes they generate.

Examples

1
2
3
4

SparseMSE/sparsemse documentation built on May 7, 2019, 7:13 p.m.