Tableau Scatter Plot

What is Tableau Scatter Plot?

Tableau Scatter plot is a data visualization tool that plots two measures or variables on a chart at the point where they intersect with each other. It is extensively used to perform data analysis, especially analyzing the relationships or correlations between two measures in a single view. The horizontal axis (x-axis) and vertical axis (y-axis) each contain data points related to two different measures. Scatter plots are visually displayed as dots, circles, or symbols along the horizontal and vertical axes of the chart. They use two-dimensional coordinates or cartesian coordinates for data visualization, similar to a line chart. You can also use scatter plots to detect any outliers in the dataset.

A sample Tableau scatter plot is shown below. As you can see, this plot is based on 2 different measures i.e. Net Profit and Revenue across 2 different axes i.e. X-axis and Y-axis. There are dots or circles in different colors representing the dimension values.

Tableau Scatter Plot - Intro

Key Takeaways
  • Tableau Scatter plot plots two variables on a chart at the point where they intersect with each other.
  • It is extensively used to analyze the relationships or correlations between two measures in a single view.
  • Tableau scatter plot comes with different features such as data visualization options, adding a scatter plot trend line for data patterns, a reference line for data comparison, and interactivity and filtering.
  • You can create a scatter plot in Tableau by plotting two measures in the Rows and Columns section and adding dimensions to the view.
  • You can add animations to your scatter plot, perform data quality handling, and export the chart to different formats for collaboration.

Features

The key features of the Tableau scatter plot are outlined below:

  • Visualization
    • Tableau has the Marks card that provides multiple features to customize the size, shape, appearance, color, and details of the data points of the scatter plot.
    • You can also add a tooltip and label the chart with the required information.
  • Tableau scatter plot trend line
    • The addition of a Trend line to the scatter plot provides insight into the hidden pattern or overall direction of the data.
  • Reference Line
    • You can add a reference line for comparing the data with a specific value.
  • Interaction and Filtering
    • You can add interactivity and apply data filtering to your scatter plot to make it visually appealing.

In the next section, we will go through the step-by-step process to create a scatter plot with Tableau.

How to create a scatter plot with Tableau?

To create a scatter plot with Tableau, follow the instructions below:

Step 1: Navigate to the Data Source tab and import the desired dataset into Tableau using the File Navigator.

Step 2: Navigate to a new worksheet by clicking on the New Worksheet icon. Drag the measures into the Rows and Columns section.

Ensure at least 1 measure is mapped to the Rows and Columns section. You can see, that Tableau has created a Tableau scatter plot filled circle i.e. one-mark scatter plot which is an intersection of aggregated data of Net Profit and Revenue.

Tableau Scatter Plot - Step 2

Step 3: Drag a dimension (Category) to the Color on the Marks card. As you can see, this has split the data into 3 Tableau scatter plot filled circles or marks as per each category value.

Tableau Scatter Plot - Step 3.jpg

Step 4: Drag the sub-category dimension to the Detail on the Marks card. Now, you can see there are multiple marks or Tableau scatter plot filled circles. Tableau has created multiple marks by multiplying the number of Sub-category values with the number of Category values.

Tableau Scatter Plot - Step 4

Step 5: Navigate to the Analytics pane and drag the Trend Line model to the view. Drop the model on the model type i.e. Linear. You may also choose the other available options depending on your dataset.

Tableau Scatter Plot - Step 5.jpg

This will add 3 different scatter plot trend lines for each color of the category values to your scatter plot as shown below.

Tableau Scatter Plot - Step 5 - trend lines

Note: Currently Tableau scatter plot matrix is not natively supported in Tableau. However, you can implement the same by tweaking the scatter plot process though it is not ideal. For creating a scatter plot matrix, consider other tools such as R. 

You may experience Tableau scatter plot overlapping points in the view especially when you have multiple measures to plot. Such views are not easy to read and create challenges for the users in data interpretation. In such scenarios, you may consider the below options

  • Adjust the size of the marks
  • Consider changing the shapes from circles to other shapes such as square
  • Change the opacity of the shapes to create transparency
  • Explore other chart options for better data visualization

Examples

In this section, we will go through different examples demonstrating the Tableau Scatter Plot.

Example #1 – Without aggregation

In this example, we will demo creating a scatter plot without aggregation in Tableau using the Banana Export Dataset. The Banana Export Dataset derived from the United States Food and Agriculture Organization (FAO), contains the banana exports by various countries from 1994 to 2005. 

To create a Tableau Scatter Plot, follow the instructions below:

Step 1: Navigate to the Data Source tab. Click on File – Open and select the dataset from your machine to import in Tableau.

Tableau Scatter Plot - Example 1 - Step 1.jpg

Step 2: Click on the New Worksheet icon and navigate to a new worksheet. In the new worksheet, drag Year and Value to Columns and Rows section respectively. Tableau will aggregate the measure as shown in the view.

Tableau Scatter Plot - Example 1 - Step 2.jpg

Step 3: Click on the down arrow next to the SUM(Value) and from the context menu, choose Dimension. This will not aggregate the measure i.e. Value.

Tableau Scatter Plot - Example 1 - Step 3.jpg

This will create a scatter chart as shown below.

Tableau Scatter Plot - Example 1 - Step 3 - chart

Step 4: Drag Domain to Color on the Marks card. Drag Country to Filters shelf. In the Filter window, choose the values to be filtered and click on Apply.

Tableau Scatter Plot - Example 1 - Step 4.jpg

This will apply a filter to the visual as shown below.

Tableau Scatter Plot - Example 1 - Step 4 - chart

Step 5: Navigate to the Analytics pane and drag the Trend Line model to the view. Drop the model on the model type i.e. Linear.

Tableau Scatter Plot - Example 1 - Step 5.jpg

You will see a trend line for your scatter plot in the view.

Tableau Scatter Plot - Example 1 - Step 5. - chart

Example #2 – With 2 dimensions

Now in this example, we will demonstrate the scatter plot with 2 dimensions using the US Store Sales dataset. The US Store Sales dataset contains the sales data in different stores across the US and provides a view of the details such as invoice details, quantity sold, cost price, sell price, and other details.

To create a Tableau scatter plot with 2 dimensions, follow the step-by-step instructions below:

Step 1: Import the US Store Sales in Tableau using the File Navigator.

Step 2: Navigate to the New Worksheet tab. Drag two measures to the Rows and Columns section.

In this case, we have dragged the Selling Price Per Unit and Cost Price Per Unit measures to the Columns and Rows section respectively.

This will create a one-mark scatter plot in the view as shown below

Tableau Scatter Plot - Example 2 - Step 2

Step 3: Now drag the Apparel Category dimension to the Color in the Marks card.

Tableau Scatter Plot - Example 2 - Step 3.jpg

Step 4: Drag the Region dimension to the Detail on the Marks card.

Tableau Scatter Plot - Example 2 - Step 4.jpg

This will add details to your scatter chart view.

Tableau Scatter Plot - Example 2 - Step 4 - chart

Step 5: Navigate to the Analytics pane. Drag the Trend Line model to the view and drop it on the model type. Here we have chosen the model type as Linear.

Tableau Scatter Plot - Example 2 - Step 5.jpg

This will add a trend line to your scatter plot in the view as shown below.

Tableau Scatter Plot - Example 2 - Step 5. - scatter chart

Example #3 – With two Filtered Categories

In this example, we will create a Tableau scatter plot with two filtered categories using the Video Game Revenue dataset. The Video Game Revenue contains the list of video game details along with their sales distribution across different regions across the globe.

To create a Tableau scatter plot with two filtered categories, follow the steps outlined below:

Step 1: Import the Video Game Revenue dataset into Tableau using the File Navigator.

Step 2: Navigate to a new worksheet.

Step 3: In the new worksheet, drag the Europe Revenue to Rows and North America Revenue to Columns section. 

Note that both the measures are aggregated.

Example 3 - Step 3.jpg

Step 4: Drag the Game Genre to the Color on the Marks card.

Example 3 - Step 4.jpg

This will create multiple marks for each Game Genre as shown below.

Example 3 - Step 4. - game genre

Step 5: Drag the Game Platform dimension to the Filters shelf. Specify the values from the list. Click on Apply to save the changes.

Example 3 - Step 5

Step 6: Similarly drag the Game Genre to the Filters shelf and specify the values for the filter conditions.

This will create a filtered scatter plot as shown below.

Example 3 - Step 6

Step 7: In the Analytics pane, drag the Trend Line model to the view and drop it on the model type. Choose the model type as Linear.

Example 3 - Step 7.jpg

Now your final scatter plot is ready for visualization. You can notice the Tableau scatter plot trend line added to your scatter plot.

Tableau Scatter Plot - Example 3 - Step 7 - chart

Important Things to Note

The important things to note on the Tableau Scatter Plot include:

  • Scatter plots require two measures/numerical values to be plotted in a cartesian plane
  • Using dimensions that have multiple values may clutter the scatter plot making it difficult to interpret and visualize
  • Be cautious with the data outliers as they may significantly impact the relationship or correlations between the measures
  • While the use of Tableau scatter plot trend lines can provide you with a pattern of your dataset, perform additional analysis to establish the causation and linkage
  • Always follow the best practices concerning data visualizations such as color, labeling, adding tooltips, and size and shape of the view

Frequently Asked Questions (FAQs)

1. Can I create a scatter plot with more than two variables in Tableau?

Yes, you can create a scatter plot with more than two variables in Tableau. However, note that this will clutter the scatter plot and make it visually complex to interpret and analyze. While you can leverage different colors, sizes, shapes, and label options to encode, it is recommended that you use a limited set of variables for your scatter plot for meaningful visualization.

2. Is it possible to animate a scatter plot in Tableau?

To animate a Tableau scatter plot, follow the instructions below:

Step 1: Navigate to the Format – Animations.



Step 2: Specify the configuration in the Animations pane. You can specify the duration of the animation and the style of your visual. You can also specify whether the animation is applied to the workbook by default.



Step 3: Play the animation by clicking on the Replay Animation icon.

3. Can I export or share scatter plots created in Tableau?

Yes, you can export the scatter plots created in Tableau by navigating to the Worksheet – Export.
You can export the scatter plots in images, Data, or spreadsheets. You can also export in PDF format.
You may consider saving the scatter plots in the Tableau server for others to access the chart.

4. How can I handle missing or null values in a scatter plot in Tableau? 

Tableau provides multiple ways to handle missing or null values in a scatter plot. These include:

• Apply filters to exclude any null values in your data fields
• Replace null or missing values with a default value for your calculations or visualization purposes
• You may also choose to highlight the missing or null values through color encoding in your visual.

This has been a guide to Tableau Scatter Plot. Here we explain how to create a scatter plot in Tableau with examples, features, and points to remember. You can learn more from the following articles –

Reader Interactions

Leave a Reply

Your email address will not be published. Required fields are marked *