I'm writing code to flag data. In this one dataset, we have medical kits supplied to different subjects. each subject comes in somewhere between 1 to 8 times, and each visit is labeled as V1-V8. i need to make sure that the id number on a medical kit given to a subject on his last visit, matches the same one he received on his prior visits. ex: Kit# Subject Visit 22 01 V1 22 01 V2 44 02 V1 45 02 V2 in the example, subject one would be fine, because they were given the same medical kit. Subject 2 would flag, because they were given a different medical kit than in previous visits.
... View more