| eff_F | R Documentation |
Computes the effective F statistic.
eff_F(data, Y, D, Z, controls = NULL, FE = NULL, cl = NULL,
weights = NULL, prec = 4)
data |
name of a dataframe. |
Y |
a string indicating the outcome variable. |
D |
a string indicating the treatment variable. |
Z |
a vector of strings indicating the instrumental variables. A factor or character instrument enters as dummy variables for all its levels but the first (base) level, named |
controls |
a vector of strings indicating the control variables. |
FE |
a vector of strings indicating the fixed effects variables. |
cl |
a string indicating the clustering variable. |
weights |
a string indicating the variable that stores weights. |
prec |
precision of results (4 by default). |
The instruments must be identified: after the intercept, controls and fixed
effects are partialled out, they must be linearly independent of each other
and not (numerically) zero. Otherwise eff_F() stops with an error.
Collinear controls are harmless and are ignored. The instruments are centred
and scaled internally; the effective F does not depend on their scale or mean.
This is not done with two or more clustering variables: lfe then repairs the
multiway cluster variance in a way that depends on the scale of the
regressors, and the instruments are used as they are, so that with one
instrument the effective F equals the cluster-robust F of ivDiag().
the effective F statistic.
Olea, José Luis Montiel, and Carolin Pflueger. 2013. "A Robust Test for Weak Instruments."" Journal of Business & Economic Statistics 31 (3): 358–69.
ivDiag
data(ivDiag)
effF <- eff_F(data = mcclendon, Y = "intended", D = "openedesteem",
Z = "esteem", controls = NULL)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.