kosukeimai / MatchIt

R package MatchIt
204 stars 43 forks source link

MatchIt for matching control with multiple group of treatment #169

Open Shawane-Wang opened 1 year ago

Shawane-Wang commented 1 year ago

Hi. I have a dataset aiming to compare dose response effect of treatment v.s. a control group, which means I need to matching the control with at least 2 people -- one from dose A group and another from dose B group simultaneously . I am wondering whether MatchIt package could help address this issue? If so, could we use rank-based mahalanobis diastance with caliper on propensity score and match by using optimal matching method? Furthermore, I want to exact match on a specific variable. Could you give any suggestions?

ngreifer commented 1 year ago

MatchIt doesn't currently support matching for multicategory treatments, but it is a feature I am working on and should be released later his year. It will accompany a major update to MatchIt. If you are interested in being an alpha tester, let me know. I have the procedure for nearest neighbor and optimal matching done at this point, and you could try it out on your dataset to see if it works.

Remember that optimal matching cannot be used with a caliper, as explained in the documentation. This is a limitation of the optmatch package, not an issue with MatchIt. Nearest neighbor matching works fine, though. I would encourage you to think not of a particular distance metric and matching method you want to use and instead try a variety of methods to find the one that yields the best balance. For example, if you can achieve good balance without a caliper, you should not use a caliper, so deciding to use a caliper before you have even attempted the matching is not a good way to look at the procedure.

There are alternatives to matching for multi-category treatments. Weighting for multi-category treatments is well-developed and has been available in the WeightIt package for many years. Is there a reason you don't want to use weighting?

Shawane-Wang commented 1 year ago

Tkanks for your kind reply! I would be glad and honored to be an alpha tester!

Thanks for your suggestions! I think I'd try other methods to reach the optimal balance before final decision. I put that question (about caliper, distance and so on) beforehand to ensure the implementability of the packages and avoid switching among different packages. However, I would take your advise!

As for the question about weighting for multi-category treatments. Actually, my data is about omics, and it seems that the IPW is not widely applied in many pipelines and mainstream softwares. It would be more straightforward to directly compare bwteen different groups than using weights in the downstream analysis. So I really hope the concept of optimal full matching could be realized on multicategory treatments, which would greatly keep my sample size.

Do look foward to your newly release! Thanks for your kind reply again!

ngreifer commented 1 year ago

That's a good reason to use matching over weighting. That said, full matching must be analyzed using weights just like propensity score weighting, so I don't think that will be a good method for you to use. I think 1:1 matching will likely be a good option to avoid the need for matching weights. Shortly, I'll send over a draft of the new version of the package with instructions on how to use and install it.

Shawane-Wang commented 1 year ago

Great! Thanks!

jiuzhouhao commented 7 months ago

Can I please test for multi-group matching as well?