3 Replies Latest reply on Aug 13, 2018 9:36 AM by Joanna Peng

    Making Tables in Tableau and Issues with Data Manipulation

    Joanna Peng

      Hello Tableau Community! I’m an intern at Fred Hutch Cancer Research Center and am specifically employed by HVTN (HIV Vaccine Trials Network.) My project is to convert an excel style table into Tableau. I understand Tableau wasn’t traditionally made for table projects, but a major shareholder of our network likes simple tables rather than colorful graphs and visualizations. To introduce and ease our team into Tableau, we are committed to recreating our excel style tables using tableau while pairing them with a more modern visualization (also created by Tableau.) However, I’m having a frustrating time trying to input the data in an organized and efficient manner. I have attached a PDF that exhibits the type of data I’m working with and the format of the table I need to make. HVTN has different clinical trials that they practice, and these various clinical trials are known as protocols (the different protocols will occupy the first column in my table… As exhibited in the PDF.) Every week or so, new patients are introduced to these trials/protocols. For the second column of my table, I need to input the 1st week the clinical trial/protocol begins. The issue is that each protocol starts during a different week, month, or even year. Is there some way to write a calculated field that can extract the first date of each specific protocol so that all these dates are put in 1 orderly column (next to the Protocol column)? I’ve tried making a sheet for each individual protocol in which I filter all the protocol’s dates to find the first one. This way, I would have make an annoying number of sheets and then subsequently shove them onto a dashboard together. Doing it this way is annoying, time-consuming, and messy. I hope someone can share a simpler solution to my dilemma.


      A note to whoever is trying to help me: The “protocol” dimension obviously stands for all the Protocols, and you will want to use the dimension “Enrolldt” to find the 1St Week that the Trial/Protocol begins. Also, I appreciate your attempt in helping with this issue. Also, the packaged workbook posted below is Desktop Version 2018.2

        • 1. Re: Making Tables in Tableau and Issues with Data Manipulation



          I think there should be a simpler way to address your issue.

          I was not able to get to your workbook because it seemed

          to be asking about a connection to a Tableau Online datasource.

          I think you will need to extract your data first before packaging:

          Packaged workbooks and flows: when, why, how


          If there is any data therein that it would be better not to share,

          then I would suggest posting an excel dateset with fake data

          in a layout similar to your true set.


          Either Level of Detail calculations or Table Calculations

          should be able to return to you the first date.

          • 2. Re: Making Tables in Tableau and Issues with Data Manipulation



            My apologies, I remain unable to get to your workbook.

            Not sure if it is something on my side.

            Please see screenshot below.


            Regardless, I don't think it's necessary at this stage.

            Some simple mock up data in an Excel spreadsheet

            should suffice, as long as it's in the same layout by

            rows and columns as your true datasource.

            You can just take the first few lines of your source

            and change any names you feel necessary.


            My apologies also if you have already tried these, but here is information

            on Level of Detail calculations, which should be amenable for use in your

            general case: Overview: Level of Detail Expressions


            In your specific case, the calculated field would look something like,

            in it's simplest form:

            { FIXED [ProtocolName] : MIN ( [Datefield] ) }


            which should take the earliest date in your dataset for each specific Protocol

            and fix it to every row in your dataset that has that same Protocol Name.

            So regardless of how things get filtered on your view, that date should remain.


            If you do have need for other dimensions, just making up an example, if

            you need to see the earliest date for only patients of Cancer Type A, and

            separately for Cancer Type B, then you would modify the calculated field to be:


            { FIXED [ProtocolName], [CancerType] : MIN ( [Datefield] ) }



            • 3. Re: Making Tables in Tableau and Issues with Data Manipulation
              Joanna Peng

              Thanks! This calculated field worked beautifully.