Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
From | Phil Schumm <pschumm@uchicago.edu> |
To | Statalist Statalist <statalist@hsphsun2.harvard.edu> |
Subject | Re: st: Puzzling error with merge |
Date | Mon, 13 Jan 2014 15:31:18 -0600 |
On Jan 13, 2014, at 3:11 PM, David Hoaglin <dchoaglin@gmail.com> wrote: > On each of those Stata data files, I used -tabulate- with StudyID as a categorical variable (its type is string). I expected the output to show a frequency of 2 (or more) for any duplicate, but each value of StudyID had a frequency of 1 in both files, and the total frequency was correct in both files. That is exactly what you would see if you have observations for which StudyID is missing (i.e., they would not appear in the table). Try assert !mi(StudyID) in both datasets; if this fails, you can either count if mi(StudyID) or examine the data in the Browser. -- Phil * * 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/