att {hbal} | R Documentation |
Estimating the ATT from an hbal object
Description
att
estimates the average treatment effect on the treated (ATT) from an
hbal object returned by hbal
.
Usage
att(hbalobject, method="lm_robust", dr=TRUE, displayAll=FALSE, ...)
Arguments
hbalobject |
an object of class |
method |
estimation method for the ATT. Default is the Lin (2016) estimator. |
dr |
doubly robust, whether an outcome model is included in estimating the ATT. |
displayAll |
only displays treatment effect by default. |
... |
arguments passed to lm_lin or lm_robust |
Details
This is a wrapper for lm_robust
and lm_lin
from the estimatr package.
Value
A matrix of estimates with their robust standard errors
Author(s)
Yiqing Xu, Eddie Yang
Examples
#EXAMPLE 1
set.seed(1984)
N <- 500
X1 <- rnorm(N)
X2 <- rbinom(N,size=1,prob=.5)
X <- cbind(X1, X2)
treat <- rbinom(N, 1, prob=0.5) # Treatment indicator
y <- 0.5 * treat + X[,1] + X[,2] + rnorm(N) # Outcome
dat <- data.frame(treat=treat, X, Y=y)
out <- hbal(Treat = 'treat', X = c('X1', 'X2'), Y = 'Y', data=dat)
sout <- summary(att(out))
[Package hbal version 1.2.12 Index]