The didet package provides tools for differences-in-differences (DiD) estimation when the treatment variable of interest may be non-binary and its value may change in each time period. The package implements the doubly robust estimation of the average treatment effect for movers using the concept of effective treatment. For more details, see Yanagi (2023) “An effective treatment approach to difference-in-differences with general treatment patterns”.
Installation
Get the package from GitHub:
# install.packages("devtools") # if necessary
devtools::install_github("tkhdyanagi/didet", build_vignettes = TRUE)
References
- Yanagi, T., 2023. An effective treatment approach to difference-in-differences with general treatment patterns. arXiv preprint arXiv:2212.13226. Link