Learn R Programming

lllcrc (version 1.2)

vgam.crc: Build a VGAM CRC model

Description

A high-level function to fit a VGAM CRC model to standardized data (the output of format.data).

Usage

vgam.crc(dat, models = make.hierarchical.term.sets(k = attributes(dt)$k), sdf, llform = NULL, round.vars = NULL, rounding.scale = NULL, boot.control = NULL)

Arguments

dat
The CRC data, as output of format.data
models
A list of models -- or an expression that returns a list of models -- to be considered in local model search. Run the default, make.hierarchical.term.sets(k = attributes(dat)$k), to see an example.
sdf
A vector, with length corresponding to the number of continuous predictor variables, that states the desired effective degrees of freedom for the corresponding smooth spline in VGAM.
llform
A character vector of predictors of the form "c1", "c2" for main effects, or "c12" for an interaction. By default, the function AICc.vgam is used to select the best set of terms among the candidate sets that are proposed by the function make.hierarchical.term.sets.
round.vars
See micro.post.stratify, which is called within vgam.crc.
rounding.scale
See micro.post.stratify, which is called within vgam.crc.
boot.control
A list of control parameters for bootstrapping the sampling distribution of the estimator(s). By default, there is no bootstrapping.

Value

est
A point estimate of the population size
llform
The set of log-linear terms
dat
The output of function micro.post.stratify, with estimated local rates of missingness appended as an extra column labeled pi0. In addition, mct (multinomial cell count) gives the number of observed units with that distinct covariate vector, and cpi0 (cumulative number missing) gives the the product of pi0 with mct, such that summing over this vectorized product is exactly the Horvitz-Thompson style sum in capture recapture.
aic
The AICc for the chosen VGAM, as computed by function AICc.vgam
mod
The VGAM model object; see the vgam function in package VGAM for details
...
The output is of class vgam.crc and has attributes cont.x and conteg.x, which relate the continuous and categorical variables in the model

Details

Implements, approximately, the method of Zwane (2004). Serves mainly as a user-friendly interface to the VGAM package.

References

Zwane E and Heijden Pvd (2003). "Implementing the parametric bootstrap in capture-recapture models with continuous covariates." Statistics & Probability Letters, 65, pp. 121-125.

Zwane E and Heijden Pvd (2004). "Semiparametric models for capture-recapture studies with covariates." Computational Statistics & Data Analysis, 47, pp. 729-743.