el_glm {melt} | R Documentation |
Empirical likelihood for generalized linear models
Description
Fits a generalized linear model with empirical likelihood.
Usage
el_glm(
formula,
family = gaussian,
data,
weights = NULL,
na.action,
start = NULL,
etastart = NULL,
mustart = NULL,
offset,
control = el_control(),
...
)
Arguments
formula |
An object of class |
family |
A description of the error distribution and link function to be used in the model. Only the result of a call to a family function is supported. See ‘Details’. |
data |
An optional data frame, list or environment (or object coercible
by |
weights |
An optional numeric vector of weights to be used in the
fitting process. Defaults to |
na.action |
A function which indicates what should happen when the data
contain |
start |
Starting values for the parameters in the linear predictor.
Defaults to |
etastart |
Starting values for the linear predictor. Defaults to |
mustart |
Starting values for the vector of means. Defaults to |
offset |
An optional expression for specifying an a priori known
component to be included in the linear predictor during fitting. This
should be |
control |
An object of class ControlEL constructed by
|
... |
Additional arguments to be passed to |
Details
Suppose that we observe independent random variables
from a common distribution, where
is the
-dimensional covariate (including the intercept if any) and
is the response. A generalized linear model specifies that
,
, and
,
where
is an unknown
-dimensional parameter,
is an optional dispersion
parameter,
is a known smooth link function, and
is a known
variance function.
With denoting the inverse link function, define the quasi-score
Then we have the estimating equations
.
When
is known, the (profile) empirical likelihood ratio for a
given
is defined by
With unknown , we introduce another estimating function based on
the squared residuals. Let
and
Now the empirical likelihood ratio is defined by
el_glm()
first computes the parameter estimates by calling glm.fit()
(with ...
if any) with the model.frame
and model.matrix
obtained from
the formula
. Note that the maximum empirical likelihood estimator is the
same as the the quasi-maximum likelihood estimator in our model. Next, it
tests hypotheses based on asymptotic chi-square distributions of the
empirical likelihood ratio statistics. Included in the tests are overall
test with
and significance tests for each parameter with
The available families and link functions are as follows:
-
gaussian
:"identity"
,"log"
, and"inverse"
. -
binomial
:"logit"
,"probit"
, and"log"
. -
poisson
:"log"
,"identity"
, and"sqrt"
. -
quasipoisson
:"log"
,"identity"
, and"sqrt"
.
Value
An object of class of GLM.
References
Chen SX, Cui H (2003). “An Extended Empirical Likelihood for Generalized Linear Models.” Statistica Sinica, 13(1), 69–81.
Kolaczyk ED (1994). “Empirical Likelihood for Generalized Linear Models.” Statistica Sinica, 4(1), 199–218.
See Also
EL, GLM, el_lm()
, elt()
,
el_control()
Examples
data("warpbreaks")
fit <- el_glm(wool ~ .,
family = binomial, data = warpbreaks, weights = NULL, na.action = na.omit,
start = NULL, etastart = NULL, mustart = NULL, offset = NULL
)
summary(fit)