addreg.control {addreg}R Documentation

Auxiliary for Controlling addreg Fitting

Description

Auxiliary function for addreg fitting. Typically only used internally by nnpois and nnnegbin, but may be used to construct a control argument to these functions.

Usage

addreg.control(bound.tol = 1e-06, epsilon = 1e-10, maxit = 10000, trace = 0)

Arguments

bound.tol

positive tolerance specifying the interior of the parameter space. If the fitted model is more than bound.tol away from the boundary of the parameter space then it is assumed to be in the interior. This can allow the computational method to terminate early if an interior maximum is found. No early termination is attempted if bound.tol = Inf.

epsilon

positive convergence tolerance ε; the estimates are considered to have converged when √{ ∑ (θ_{old} - θ_{new})^2} / √ {∑ θ_{old}^2} < ε, where θ is the vector of parameter estimates. See conv.test.

maxit

integer giving the maximum number of EM algorithm iterations for a given parameterisation.

trace

number indicating level of output that should be produced. >= 1 gives output for each parameterisation, >= 2 gives output at each iteration.

Details

This is used similarly to glm.control. The control argument of addreg is by default passed to the control argument of nnpois or nnnegbin.

When trace is greater than zero, calls to cat produce the output. Hence, options(digits = *) can be used to increase the precision.

Value

A list with components named as the arguments.

Author(s)

Mark W. Donoghoe markdonoghoe@gmail.com

See Also

glm.control, the equivalent function for glm fitting.

nnpois and nnnegbin, the functions used to fit addreg models.

Examples

## Variation on example(glm.control) :

counts <- c(18,17,15,20,10,20,25,13,12)
outcome <- gl(3,1,9)
treatment <- gl(3,3)
oo <- options(digits = 12)
addreg.D93X <- addreg(counts ~ outcome + treatment, family = poisson, 
  trace = 2, epsilon = 1e-2)
options(oo)
coef(addreg.D93X)

[Package addreg version 3.0 Index]