Dear Stata listers,
I have two datasets and each has a unique id – the patient id.
One dataset (the larger) contains patient demographic data and the
other dataset (the smaller) contains the results of a laboratory test.
(Not all patients had the laboratory test done).
I would like to merge the two datasets.
I have tried a one to one merge based on the patient id. The two
datasets do merge, however a patient is paired with the wrong
laboratory result (i.e. a result which is not the patient’s, but
belonging to another patient).
How can I merge the two datasets so that the two datasets are
correctly merged (each patient with their correct lab result)?
Kind regards,
Gwinyai
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/