WeightIt
WeightIt copied to clipboard
DAPSm weighting
Great package! Could this weighting method also be implemented?
https://github.com/gpapadog/DAPSm
This isn't a weighting method, it's a matching method, and so would be better suited for MatchIt
(which I also maintain). However, you can already use the method with MatchIt
. I'll provide instructions here in case you are interested in using it within the MatchIt
framework.
DAPS involves computing a weighted average between the propensity score distance between units and the spatial distance between units, i.e., $d_{ij} = w * |ps_i - ps_j| + (1 - w) \text{Dist}_{ij}$. You can compute the propensity score distance between units by estimating the propensity score and then supplying it to euclidean_dist()
. Then you can compute the spatial distance however you want (e.g., using the instructions in the article). Then you pick a value of $w$ and compute the new distance as w * ps_dist_mat + (1 - w) * spat_dist_mat
. You can supply this to the distance
argument of matchit()
to do whatever kind of matching you want using it (e.g., nearest neighbor, optimal, etc.).
Given that this method is very specific to spatial applications and can be implemented easily without much programming, I'm not inclined to add it as a fixed feature to MatchIt
.