optmatch icon indicating copy to clipboard operation
optmatch copied to clipboard

Better error messages for not enough control unit type failures

Open markmfredrickson opened this issue 7 years ago • 1 comments

Pairmatches can fail when there are not enough control units available. This can be particularly confusing with a caliper that forces, say, 10 treated units to share 9 control units. Can we detect this prob lem in advance and provide better warnings?

markmfredrickson avatar Aug 02 '17 19:08 markmfredrickson

With the recent updates for #129, we may be catching a somewhat greater share of these cases than previously, by more reliably flagging subclasses in which the number of controls can be seen to be insufficient once the ineligible-for-matching controls have been removed. (I don't believe this last bit was being figured into the calculation previously.)

Does if make sense to try to go further than this, e.g. pre-counting for each treatment the number of controls she's connected to by an arc, then quitting with an informative error if any of them are smaller than the controls arg that came w/ the pairmatch call? Maybe, maybe not.

The argument against is that you could readily have situations in each treatment has enough eligible matches, but the same eligible matches are shared among too many treatments. There's no hope of flagging this short of running things through the solver. But from the user perspective it may seem a similar enough problem that we'd be raising false hopes by addressing the problem of this issue without also addressing it.

I'd vote to spend time on this only if it looked like a limited amount of time and it looked like a limited amount of time cost in precomputation.

benthestatistician avatar Aug 02 '17 21:08 benthestatistician