To cite the paper that the R did package is based on:

Callaway B, Sant'Anna P (2021). “Difference-in-differences with multiple time periods.” Journal of Econometrics. https://doi.org/10.1016/j.jeconom.2020.12.001.

To cite the did R package:

Callaway B, Sant'Anna P (2021). “did: Difference in Differences.” R package version 2.1.0, https://bcallaway11.github.io/did/.

Corresponding BibTeX entries:

  @Article{,
    title = {Difference-in-differences with multiple time periods},
    author = {Brantly Callaway and Pedro H.C. Sant'Anna},
    year = {2021},
    journal = {Journal of Econometrics},
    url = {https://doi.org/10.1016/j.jeconom.2020.12.001},
  }
  @Misc{,
    title = {did: Difference in Differences},
    author = {Brantly Callaway and Pedro H.C. Sant'Anna},
    year = {2021},
    note = {R package version 2.1.0},
    url = {https://bcallaway11.github.io/did/},
  }