[R] ivreg with two endogenous variables and 1 instrument respectively

Achim Zeileis Achim.Zeileis at uibk.ac.at
Wed Mar 9 18:02:28 CET 2016

On Tue, 8 Mar 2016, stefania innocenti wrote:

> Hello,
> I am trying to use the ivregress function to estimate a second stage 
> model which looks like the following:
> I would like to instrument Rule (RULE) with Settler mortality (SETTLER) 
> and Openness (OPENNESS) with logFrankelRomer (FR). I thus have one 
> instrument per each endogenous variable.
> Thus the second stage look like:
> Can I do this simultaneously with the ivregress function?

Which package is this?

> Maybe I got something wrong with the syntax but if I do:
> OPENNESS~SETTLER+FR+GEO), mydata), the function bugs and I cannot 
> proceed.
> Of course, I could run the two first stages separately, but the 
> coefficient of the first stage are then wrong.
> The command ivreg(logGDP ~ RULE + GEO +OPEN| GEO + SETTLER+FR) gives me 
> correct second stage coefficients (I checked with what I obtained doing 
> the 2sls by hand).

That's package "AER", I presume?

> But how do I retrieve the first stage coefficients for 

The ivreg() function from "AER" does not store the first stage results but 
just returns the IV estimates from the second stage. If you want the first 
stage you need to run lm() manually:

lm(cbind(RULE, OPENNESS) ~ GEO + logFR + SETTLER, ...)

> Any advice is more than appreciated.
> Thanks a lot in advance.
> Best regards,
> Stefania
> ______________________________________________
> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

More information about the R-help mailing list