Description Usage Arguments Methods Examples
It estimates a linear model using two-stage least squares.
1 2 | ## S4 method for signature 'linearGmm'
tsls(model)
|
model |
An object of class |
signature(model = "linearGmm")
signature(model = "slinearGmm")
2SLS for equation by equation estimation of a system of equations.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | x <- rchisq(200,5)
z1 <- rnorm(200)
z2 <- .2*x+rnorm(200)
y <- x+rnorm(200)
dat <- data.frame(y=y,z1=z1,x=x,z2=z2)
theta <- c(beta0=1,beta1=2)
model1 <- gmmModel(y~x, ~z1+z2, data=dat)
res <- tsls(model1)
summary(res)
## Econometrics, Fumio Hayashi (2000)
## Empirical exercises (b) and (c)
data(Griliches)
Griliches$YEAR <- as.factor(Griliches$YEAR)
model1 <- gmmModel(LW~S+IQ+EXPR+TENURE+RNS+SMSA+YEAR-1,
~S+EXPR+TENURE+RNS+SMSA+YEAR+MED+KWW+MRT+AGE-1,
data=Griliches, vcov="MDS")
res <- tsls(model1)
summary(res)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.