vcovvlm | R Documentation |
Returns the variance-covariance matrix of the
parameters of
a fitted vlm-class
or
rrvglm-class
or
drrvglm-class
object.
vcovvlm(object, dispersion = NULL, untransform = FALSE,
complete = TRUE, ...)
vcovrrvglm(object, ...)
vcovdrrvglm(object, ...)
vcovqrrvglm(object, ...)
object |
A fitted model object,
having class |
dispersion |
Numerical. This argument should not be used as VGAM will be phasing out dispersion parameters. Formerly, a value may be specified, else it is estimated for quasi-GLMs (e.g., method of moments). For almost all other types of VGLMs it is usually unity. The value is multiplied by the raw variance-covariance matrix. |
untransform |
logical.
For intercept-only models with trivial
constraints;
if set |
complete |
An argument currently ignored.
Added only so that
|
... |
Same as |
This methods function is based on the QR decomposition
of the (large) VLM model matrix and working weight matrices.
Currently
vcovvlm
operates on the fundamental
vlm-class
objects because pretty well
all modelling functions in VGAM inherit from this.
Currently
vcovrrvglm
is not entirely reliable because the elements of the
A–C part of the matrix sometimes cannot be
computed very accurately, so that the entire matrix is
not positive-definite.
For "qrrvglm"
objects,
vcovqrrvglm
is currently working with Rank = 1
objects or
when I.tolerances = TRUE
.
Then the answer is conditional given C.
The code is based on
model.matrixqrrvglm
so that the dimnames
are the same.
Same as vcov
.
For some models inflated standard errors can occur, such as
parameter estimates near the boundary of the parameter space.
Detection for this is available for some models using
hdeff.vglm
, which tests for an
Hauck-Donner effect (HDE) for each regression coefficient.
If the HDE is present, using
lrt.stat.vlm
should return more accurate p-values.
Thomas W. Yee
confintvglm
,
summaryvglm
,
vcov
,
hdeff.vglm
,
lrt.stat.vlm
,
model.matrixqrrvglm
.
## Not run:
ndata <- data.frame(x2 = runif(nn <- 300))
ndata <- transform(ndata, y1 = rnbinom(nn, mu = exp(3+x2), exp(1)),
y2 = rnbinom(nn, mu = exp(2-x2), exp(0)))
fit1 <- vglm(cbind(y1, y2) ~ x2, negbinomial, ndata, trace = TRUE)
fit2 <- rrvglm(y1 ~ x2, negbinomial(zero = NULL), data = ndata)
coef(fit1, matrix = TRUE)
vcov(fit1)
vcov(fit2)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.