get_honestdid_obj_did2s: get_honestdid_obj_did2s

View source: R/honest_did.R

get_honestdid_obj_did2sR Documentation

get_honestdid_obj_did2s

Description

a helper function that takes a fixest feols object (likely from did2s) that plugs into honest_did. Note this function assumes the event study coefficients are using i() syntax, e.g. i(rel_year). This should also work for a TWFE event-study model estimated by feols.

Usage

get_honestdid_obj_did2s(est, coef_name = "rel_year")

Arguments

est

A fixest object, likely from did2s.

coef_name

Character. The name of the event-study relative-year variable name, from i(rel_year).

Value

A list containing the vector of event-study coefficients beta, the variance-covariance matrix of beta, V, and a vector of relative years, event_time.


kylebutts/did2s documentation built on April 17, 2025, 5:20 p.m.