buildmodel: Build model for multiple systems estimation

Description Usage Arguments Value Examples

Description

For multiple systems estimation model corresponding to a specified set of two-list effects, set up the GLM model formula and data matrix.

Usage

1
buildmodel(zdat, mX)

Arguments

zdat

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.

mX

A 2 \times k matrix giving the k two-list interactions to be included in the model. Each column of mX contains the numbers of the corresponding pair of lists. If mX = 0, then all two-list interactions are included. If mX = NULL, no interactions are included and the main effects model is fitted.

Value

A list with components as below.

datamatrix A matrix with all possible capture histories, other than those corresponding to empty overlaps within the model. An empty overlap is a pair of lists (i,j) such that no case is observed in both lists, regardless of whether it is present on any other lists. If (i,j) is within the model specified by mX, all capture histories containing both i and j are then excluded.

modelform The model formula suitable to be called by the Generalized Linear Model function glm

emptyoverlaps A matrix with two rows, whose columns give the indices of pairs of lists for which there are empty overlaps and where the pair is within the specified model. The column names give the names of the lists corresponding to each pair.

Examples

1
2

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