You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As noted in #365, the AER package has been superseded by a dedicated ivreg package (link). My suggestion here is based on the idea that it would be keep to keep a consistent syntax between estimatr and its "base" counterpart(s). With that in mind...
On cool feature introduced in the upcoming 0.6.0 release of ivreg is support for a three-part formula RHS:
y ~ ex | en | in
where ex is exogenous variables, en is endogenous variables, and in is instruments. In my view, this is a much more natural way of expressing the IV syntax than the old two-part formula (which is nonetheless still supported):
y ~ ex + en | ex + in
At the very least, the three-part syntax cuts down on typing since you don't have to write out the ex vars twice. It's also closer to the IV syntax used by fixest::feols() and lfe::felm(), as well as the equivalent Stata routines.
Thanks for considering.
The text was updated successfully, but these errors were encountered:
I think this is a good suggestion. I'm wary about breaking old code so I'll want to see if there's a way to do this that is "smart" enough. I'd think so given we rely on the Formula package.
As noted in #365, the AER package has been superseded by a dedicated ivreg package (link). My suggestion here is based on the idea that it would be keep to keep a consistent syntax between estimatr and its "base" counterpart(s). With that in mind...
On cool feature introduced in the upcoming 0.6.0 release of ivreg is support for a three-part formula RHS:
where
ex
is exogenous variables,en
is endogenous variables, andin
is instruments. In my view, this is a much more natural way of expressing the IV syntax than the old two-part formula (which is nonetheless still supported):At the very least, the three-part syntax cuts down on typing since you don't have to write out the
ex
vars twice. It's also closer to the IV syntax used byfixest::feols()
andlfe::felm()
, as well as the equivalent Stata routines.Thanks for considering.
The text was updated successfully, but these errors were encountered: