4 Replies Latest reply on Mar 21, 2013 7:40 AM by christian.vonhehn

    comparing specific dates of two group members

    christian.vonhehn

      Dear Tableau community,

      I am trying to plot the number of records for product XX and product YY comparing specific time points for XX and YY.

      Product XX has launched in the past (launch date XX, April 1st 2011) and product YY will launch at a certain date in the future (launch date YY, July 1st 2013); both products have different numbers of pre-launch records. I would like to display product XX and YY so that the launch dates align, and I can directly compare the activity before and after launch.

      Since I have different of different numbers of pre-launch records I cannot just use the beginning of both records (workbook is attached).

      Any ideas or suggestions will be much appreciated.

      Thank you!

      Christian.

        • 1. Re: comparing specific dates of two group members
          Dana Withers

          Hi Christian,

           

          If you want to align the launch dates, why not use a calculated field to calculate the number of days before and after launch... I created a "Days around Launch" field with the following calculation.

          case [Product]

          when "XX" then datediff("day", #01-04-2011#, [Date]) // Compare to launch date of product XX

          when "YY" then datediff("day",  #01-07-2013#, [Date]) // Compare to launch date of product YY

          end

           

          If you use unsummarised continuous data, and replace the "Month  (Date)" field with it, you get the same two rows of graphs where the 0 line is the launch date. It may still look a bit off since Product YY has records more than a year before launch date and product XX was not that well advanced, but you can see it coming up I suppose.

           

          Hope that helps,


          Dana

          • 2. Re: comparing specific dates of two group members
            christian.vonhehn

            Hi Dana,

            thank you for your reply.

            I cannot get your suggestions to work, could you add the workbook to show me?

            Thanks again,

            Christian.

            • 3. Re: comparing specific dates of two group members
              Dana Withers

              Hi Christian,

               

              I'm having a slight issue trying to upload files, so I hope this works Perhaps people are too enthusiastically downloading V8.

              Does say it is there though so keeping fingers crossed.

               

              Basically - further to the calculation that I pasted earlier, this is what I did to create the graph:

              - Drag in Products to rows

              - Drag in Days around Launch to Columns (it will automatically sum)

              - Drag in number of records to rows (will also automatically sum)

              Now because you want to see Days around Launch as a continuous x-axis, not in a summarized way, right-click the pill in the columns shelf and choose "Dimension" from the drop-down list. (two above Measure which is automatically ticked)

               

               

              Hope that helps!

               

              Dana

              1 of 1 people found this helpful
              • 4. Re: comparing specific dates of two group members
                christian.vonhehn

                Thank you, Dana!

                You have been really helpful.