moderndid.compute_identified_set_sdrm#
- moderndid.compute_identified_set_sdrm(m_bar, true_beta, l_vec, num_pre_periods, num_post_periods)[source]#
Compute identified set for \(\Delta^{SDRM}(\bar{M})\).
Computes the identified set for \(l'\tau_{post}\) under the restriction that the underlying trend delta lies in \(\Delta^{SDRM}(\bar{M})\).
The identified set is the union of identified sets for each component polyhedron, following Equation (7) in [1],
\[\mathcal{S}(\beta, \Delta) = \bigcup_{k=1}^{K} \mathcal{S}(\beta, \Delta_k).\]For \(\Delta^{SDRM}(\bar{M})\), this union is taken over all possible pre-treatment periods s where the maximum second difference could occur, and for both positive and negative signs of this maximum,
\[\mathcal{S}(\beta, \Delta^{SDRM}(\bar{M})) = \bigcup_{s<0} \left( \mathcal{S}(\beta, \Delta_{s,+}^{SDRM}(\bar{M})) \cup \mathcal{S}(\beta, \Delta_{s,-}^{SDRM}(\bar{M})) \right),\]where \(\mathcal{S}(\beta, \Delta_{s,\text{sign}}^{SDRM}(\bar{M}))\) is the identified set when the maximum pre-period second difference occurs at period \(s\) with a given sign.
For each component, we solve linear programs to find the bounds of \(l'\tau_{post}\) subject to \(\delta \in \Delta_{s,\text{sign}}^{SDRM}(\bar{M})\) and \(\delta_{pre} = \beta_{pre}\).
- Parameters:
- m_bar
float Relative magnitude parameter \(\bar{M}\). Second differences in post-treatment periods can be at most \(\bar{M}\) times the maximum absolute second difference in pre-treatment periods.
- true_beta
numpy.ndarray True coefficient values \(\beta = (\beta_{pre}', \beta_{post}')'\).
- l_vec
numpy.ndarray Vector defining parameter of interest \(\theta = l'\tau_{post}\).
- num_pre_periods
int Number of pre-treatment periods \(\underline{T}\).
- num_post_periods
int Number of post-treatment periods \(\bar{T}\).
- m_bar
- Returns:
DeltaSDRMResultLower and upper bounds of the identified set.
References
[1]Rambachan, A., & Roth, J. (2023). A more credible approach to parallel trends. Review of Economic Studies, 90(5), 2555-2591.