2 Replies Latest reply on Oct 7, 2013 12:34 PM by Lucie V

    Calculating Distinct

    Lucie V

      Hello good people!

      I have a problem, and I have tried everything I could, but I am still stuck:

      We have a patientID column and we want to know their gender based on their distinct (unique) ID, and what clinic they get treated at.

      Basically: Unique ID, then their gender and clinic location.

      When we apply the CNTD to the ID, it works and shows up all unique IDs. When we add gender, it still works great.

      But as soon as I add the facility (clinic location name) variable, the numbers are off.

      Our patient ID, gender and facility are all strings.

      How can I assure that "unique ID" comes first, then attaches gender and plots by facility location?

      Is that a calculated field? If so, what would be the syntax on that, please? Is there another way? Thank you!

        • 1. Re: Calculating Distinct
          Matt Lutton

          Can you post a packaged workbook, or screenshots, of what is happening when you add the facility/clinic to the view?  I'm not sure I understand the problem, or what result you are expecting.  If you can provide more detail, and possibly a packaged workbook, that will help you get the best answer possible.  Also, this question didn't end up in the main "Forums" section of the site, so you might want to move the original question to garner more attention.

          • 2. Re: Calculating Distinct
            Lucie V

            Thank you, Matt!

            I cannot really post the data, because it's confidential information for patients. I know that would help, but it's not possible. I can solve this possibly by adding another column with a marker that will identify the unique patient ID number per clinic and then graph that. I am matching the results to our Stata software calculations. That's where the numbers do not match.