coef
is a generic function which extracts model coefficients from
objects returned by modeling functions. coefficients
is an alias for
it.
Usage
# S3 method for lmodel2
coef(object, method = "MA", ...)
Arguments
- object
a fitted model object.
- method
character One of the methods available in
object
.- ...
ignored by this method.
Details
Function lmodel2()
from package 'lmodel2' returns a fitted
model object of class "lmodel2"
which differs from that returned by
lm()
. Here we implement a coef()
method for objects of this
class. It differs from de generic method and that for lm objects in having
an additional formal parameter method
that must be used to select
estimates based on which of the methods supported by lmodel2()
are
to be extracted. The returned object is identical in its structure to that
returned by coef.lm()
.