6 Replies Latest reply on Feb 10, 2016 7:39 AM by Bhushan Thakar

    scatter plot of customers

    Bhushan Thakar

      HI

       

      I want to create a scatter plot that shows different customer purchase transactions on different dates. So I have a data that would look something like as follows:

      Customer A: $10K on 1/1/15

      Customer A: $15K on 2/1/15

      Customer A: $13K on 2/15/15

      Customer B: $11K on 1/1/15

      Customer B: $12K on 2/1/15

      Customer B: $14K on 2/15/15

      etc..

      I want to plot Customer names on X axis and their corresponding dots on Y axis as sale values. Can I do this in Tableau and how should I do it?

       

      Thanks,

      Bhushan.

        • 1. Re: scatter plot of customers
          pooja.gandhi

          Bhushan!

           

          I think the terminology of using a scatter plot in context to what you are looking for is not what you want. Scatter plot is a correlation of 2 variables on X and Y axes for a set of values and how they correlate.

           

          You can pretty much drag customer on columns, values on rows and date (exact) on color and change the mark type to 'circle' on the marks card and you should have what you want.

           

          1 of 1 people found this helpful
          • 2. Re: scatter plot of customers
            Bhushan Thakar

            Thanks Pooja.

             

            Is there any way to plot a dot for the average of the dots for each column? e.g. I played around a bit with this plot and generated the plot below. For confidentiality reasons, I had to black out the labels for X axis. I ended up generating two charts when I dragged the Invoice measure twice--once using sum and the using average. Ideally, I would like to draw a candlestick-like chart that show a straight line connecting all the dots for each of the column variable and then plotting a dot in different color for average of those values.

             

            • 3. Re: scatter plot of customers
              pooja.gandhi

              Hey Bhushan!

               

              While dragging another instance of the invoice pill make sure there is nothing on level of detail of the 2nd marks card. You can do something like this maybe: Drag min(number of records) on columns and change the mark type of the sum(value) to line to have the line pass through the 3 dots. And change the mark type to circle for the 2nd axis avg(value):

               

              So basically the average of the 3 dots for customer B is 12,333.3

               

              • 4. Re: scatter plot of customers
                Bhushan Thakar

                Hi Pooja,

                 

                I followed your steps but I still don't have everything on one plot. I see two separate plots. I get as follows:

                How did you get everything on one plot?

                Here is what I have on Tableau rows and columns

                 

                 

                Am I missing something?

                Thanks.

                Bhushan.

                • 5. Re: scatter plot of customers
                  pooja.gandhi

                  It doesn't seem like you have exact date on color for the 1st axis and you will also want to click on the dropdown of the 2nd average pill and choose dual axis:

                   

                  • 6. Re: scatter plot of customers
                    Bhushan Thakar

                    Hi Pooja,

                     

                    I did that and now I am able to get a plot structure that I want; however, having dual axis gives me my average values that are outside the range of my actual values. I noticed the axis range for the second one is different, so I synchronized it and now I get all the average dots on the Yaxis zero line.

                     

                    How can I fix that?

                     

                    Secondly, I do not want the number or records labels visible on X axis. Instead I want the actual X axis variable that is now visible on the top of the chart to be visible on the actual X axis below the chart.

                    Note I have used here the sample Global superstore database that comes with Tableau examples. (attached here)

                     

                    Thanks,

                     

                    Bhushan