pglm | R Documentation |
Estimation by maximum likelihood of glm (binomial and Poisson) and 'glm-like' models (Negbin and ordered) on longitudinal data
pglm(
formula,
data,
subset,
na.action,
effect = c("individual", "time", "twoways"),
model = c("random", "pooling", "within", "between"),
family,
other = NULL,
index = NULL,
start = NULL,
R = 20,
method = c("bfgs", "newton"),
trace = 0,
...
)
ordinal(link = c("probit", "logit"))
negbin(link = c("log"), vlink = c("nb1", "nb2"))
formula |
a symbolic description of the model to be estimated, |
data |
the data: a |
subset |
an optional vector specifying a subset of observations, |
na.action |
a function which indicates what should happen when
the data contains |
effect |
the effects introduced in the model, one of
|
model |
one of |
family |
the distribution to be used, |
other |
for developper's use only, |
index |
the index, |
start |
a vector of starting values, |
R |
the number of function evaluation for the gaussian quadrature method used, |
method |
the optimization method, one of |
trace |
an integer |
... |
further arguments. |
link, vlink |
arguments of family functions |
An object of class "miscr"
, a list with elements:
Yves Croissant
## a binomial (probit) example
anb <- pglm(union ~ wage + exper + rural, union_wage, family = binomial('probit'),
model = "pooling", method = "bfgs", trace = 3, R = 5)
## a gaussian example on unbalanced panel data
ra <- pglm(mv ~ crim + zn + indus + nox + age + rm, hedonic, family = gaussian,
model = "random", trace = 3, method = "newton", index = "townid")
## some count data models
la <- pglm(patents ~ lag(log(rd), 0:5) + scisect + log(capital72) + factor(year), patents_rd,
family = negbin, model = "within", trace = 3, method = "newton",
index = c('cusip', 'year'))
la <- pglm(patents ~ lag(log(rd), 0:5) + scisect + log(capital72) + factor(year), patents_rd,
family = poisson, model = "pooling", index = c("cusip", "year"),
tracen = 0, method="newton")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.