moderndid.EtwfeResult#
- class moderndid.EtwfeResult(coefficients: ndarray, std_errors: ndarray, vcov: ndarray, coef_names: list, gt_pairs: list, n_obs: int, n_units: int, r_squared: float | None = None, adj_r_squared: float | None = None, data: object = None, config: object = None, estimation_params: dict = {})[source]#
Bases:
NamedTupleContainer for ETWFE regression output.
This class implements the
maketablesplug-in interface for publication-quality tables. See Publication Tables with maketables.Returned by
etwfe. Stores the saturated TWFE regression coefficients and variance-covariance matrix needed byemfxfor aggregation.- Attributes:
- coefficients
numpy.ndarray Coefficient estimates for each cohort x time interaction term.
- std_errors
numpy.ndarray Standard errors for each coefficient.
- vcov
numpy.ndarray Variance-covariance matrix of the interaction coefficients.
- coef_names
list[str] Names for each coefficient (from pyfixest).
- gt_pairs
list[tuple[float,float]] (group, time) pair for each coefficient.
- n_obs
int Number of observations used in estimation.
- n_units
int Number of unique cross-sectional units.
- r_squared
floatorNone R-squared of the regression.
- adj_r_squared
floatorNone Adjusted R-squared of the regression.
- data
objectorNone Preprocessed DataFrame (used by emfx for cell counts).
- config
objectorNone EtwfeConfig used for estimation.
- estimation_params
dict Additional estimation parameters.
- coefficients
Methods
count(value, /)Return number of occurrences of value.
index(value[, start, stop])Return first index of value.
Attributes
Adjusted R-squared of the regression.
Names for each coefficient from pyfixest.
Coefficient estimates for each cohort x time interaction term.
EtwfeConfig used for estimation.
Preprocessed DataFrame (used by emfx for aggregation).
Estimation parameters (yname, cgroup, formula, etc.).
(group, time) pair for each coefficient.
Number of observations used in estimation.
Number of unique cross-sectional units.
R-squared of the regression.
Standard errors for each coefficient.
Variance-covariance matrix of the interaction coefficients.