coef.fixest | R Documentation |
fixest
estimationThis function extracts the coefficients obtained from a model estimated with
femlm
, feols
or feglm
.
## S3 method for class 'fixest'
coef(object, keep, drop, order, collin = FALSE, agg = TRUE, ...)
## S3 method for class 'fixest'
coefficients(object, keep, drop, order, collin = FALSE, agg = TRUE, ...)
object |
A |
keep |
Character vector. This element is used to display only a subset of variables. This
should be a vector of regular expressions (see |
drop |
Character vector. This element is used if some variables are not to be displayed.
This should be a vector of regular expressions (see |
order |
Character vector. This element is used if the user wants the variables to be
ordered in a certain way. This should be a vector of regular expressions (see |
collin |
Logical, default is |
agg |
Logical scalar, default is |
... |
Not currently used. |
The coefficients are the ones that have been found to maximize the log-likelihood of the specified model. More information can be found on the models from the estimations help pages: femlm
, feols
or feglm
.
Note that if the model has been estimated with fixed-effects, to obtain the fixed-effect coefficients, you need to use the function fixef.fixest
.
This function returns a named numeric vector.
Laurent Berge
See also the main estimation functions femlm
, feols
or feglm
. summary.fixest
, confint.fixest
, vcov.fixest
, etable
, fixef.fixest
.
# simple estimation on iris data, using "Species" fixed-effects
res = femlm(Sepal.Length ~ Sepal.Width + Petal.Length +
Petal.Width | Species, iris)
# the coefficients of the variables:
coef(res)
# the fixed-effects coefficients:
fixef(res)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.