coef.trim {rtrim} | R Documentation |
Extract TRIM model coefficients.
Description
Extract TRIM model coefficients.
Usage
## S3 method for class 'trim'
coef(object, representation = c("standard", "trend", "deviations"), ...)
Arguments
object |
TRIM output structure (i.e., output of a call to |
representation |
|
... |
currently unused |
Value
A data.frame
containing coefficients and their standard errors,
both in additive and multiplicative form.
Details
Extract the site, growth or time effect parameters computed with
trim
.
Additive versus multiplicative representation
In the simplest cases (no covariates, no change points), the trim Model 2 and Model 3 can be summarized as follows:
Model 2:
Model 3:
.
Here, is the estimated number of counts at site
, time
. The parameters
,
and
are
refererred to as coefficients in the additive representation. By
exponentiating both sides of the above equations, alternative representations
can be written down. Explicitly, one can show that
Model 2:
, where
and
.
Model 3:
, where
,
and
for
.
The parameters ,
and
are referred to as
coefficients in the multiplicative form.
Trend and deviation (Model 3 only)
The equation for Model 3
,
can also be written as an overall slope resulting from a linear regression of
the over time, plus site- and time effects that
record deviations from this overall slope. In such a reparametrisation
the previous equation can be written as
where equals
minus the mean over all
(i.e. if
then
). It is not hard to show that
The
are the mean
per site
The
must sum to zero.
The coefficients and
are obtained by
setting
representation="deviations"
. If representation="trend"
,
the overall trend parameters and
from the overall
slope defined by
is returned.
Finally, note that both the overall slope and the deviations can be written in multiplicative form as well.
See Also
Other analyses:
confint.trim()
,
gof()
,
index()
,
now_what()
,
overall()
,
overdispersion()
,
plot.trim.index()
,
plot.trim.overall()
,
plot.trim.smooth()
,
results()
,
serial_correlation()
,
summary.trim()
,
totals()
,
trendlines()
,
trim()
,
vcov.trim()
,
wald()
Examples
data(skylark)
z <- trim(count ~ site + time, data=skylark, model=2, overdisp=TRUE)
coefficients(z)