I am using the R package MatchThem
to match a dataset that contains 19 control samples and 13 case samples.
After running the MatchThem
command with nearest-neighbor one-to-one matching without replacement, I see in the summary that the matched sample should now contain 13 controls and 13 cases.
I wanted to extract the matched sample dataset so that I can use other functions on this sample (e.g. survival analysis, summary table with gtsummary
, etc.), and learned that the complete()
function serves this purpose.
However, after running the complete()
function and checking the data frame, I see that this (supposedly) matched sample contains 19 controls and 13 cases, just like the initial dataset before matching!
What is the proper way of extracting the matched sample with 13 controls and 13 matched cases?