Dina V.
Dina V.

Reputation: 41

Matching 2 control matches for each case individual in r with matchit{MatchIt}

I'm trying to subset matched data with matchit function from MatchIt package in R. I want to match 2 control matches for each case individual by AGE and SEX variables. I've tried to use method="exact" and method="nearest", but I couldn't find the option to limit the number of control matches. Does anyone have any idea how to solve it within the function?

Upvotes: 3

Views: 1765

Answers (1)

Noah
Noah

Reputation: 4414

Hopefully you've solved it, but what you need is method="nearest" (if you want nearest neighbor matching), exact=c("sex", "age"), ratio=2. I strong recommend full matching though, using method=full.

Upvotes: 4

Related Questions