# How to create matched sample for sample selection method to perform?

I'm working on a project in which I only use sub sample (say the immigrant households of all households), and there is a sample selection problem that I apply the standard Heckman's sample selection approach. The question is the full sample is heterogeneous and not completely compatible to the sub sample, one of my supervisors criticize this and urges me to create some more "balancing" data at the first stage of heckman selection model,at least as a robustness check. One approach come into my mind is nearest neighbor matching, but in literature it's mainly used to deal with endogenity of treatment variable, not selection variable, I'm not sure if it's appropriate to use it in this case?If you know any literature has used this method, please attach it so I can cite to justify my practice, if it's not , please give me some suggestion which methods I can use to achieve my goal. Thank you so much

• Is your task to match every respondent of a sample with a similar respondent from another sample or pool of respondents? – ttnphns Mar 21 '15 at 9:00
• Pool of respondents.I perform selection on the full sample (include households who choose to migrant or not) previously. But give heterogeneity,now I want to create matched counterpart (Non-immigrant households) for every immigrant households using matching method (nearest neighbor),so that they share similar characteristics, and then perform the selection on this new sub sample. – zlqs1985 Mar 21 '15 at 9:32
• You might use fuzzy matching or (if you need to maximize the ovarall similarity in the matched pairs to the global maximum) Hungarian algorithm. – ttnphns Mar 21 '15 at 9:39
• Is it a statistical method or something else? I'm sorry I'm not quite familiar with this part, can it be implemented in Stata? Thank you for your suggestion way. – zlqs1985 Mar 21 '15 at 9:50
• No, not statistical. Matching task itself is not a statistical or data mining task. It is from the fields of graphs and optimization. – ttnphns Mar 21 '15 at 9:53

In terms of application, Stata has facilities for nearest neighbore matching with nnmatch and pscore2. Personally I prefer the latter because it is somewhat more straight forward. After you perform the matching you obtain an id variable for treated and control cases that were successfully matched. If you have panel data, the whole procedure gets a little more complicated but it is still straight forward if you know how to do it. The procedure is described in this answer. After you have done the matching you would simply keep the matched sample and perform your analysis as usual.