How to plot two sets of points on one scatter plot in Tableau

0 votes
I have a data set with each employee's name (rows), number of calls in 2020, revenue in 2020, revenue in 2021, and revenue in 2021. Is there a method in Tableau to display (employee's 2020 calls, employee's 2020 revenue) AND (employee's 2021 calls, employee's 2021 revenue) on the same scatter plot?

I tried to plot 2020 calls (columns) and 2021 revenue (rows) on a dual axis, however it ended up charting all conceivable (X,Y) combinations, when there should only be two points per employee (2020 data and 2021 data).

Is there a method to draw a line across each of the 2020 points if I know the slopes of the lines I want to draw?
Mar 31, 2022 in Tableau by Vaani
• 7,020 points
649 views

1 answer to this question.

0 votes

If you want one mark for each employee and year combination, the easiest option is to structure your data source such that each employee and year combination has one data row.

As a result, make changes to your data source to include the following columns:

Employee
Year
Calls
Revenue
Then try Employee on Detail, Year on colour (as a dimension), SUM(Calls) on Columns and Sum(Revenue) on Rows

If you don't want to preprocess your data, you can achieve the same result in the Data Source editing panel by UNIONing the original source with itself, adding a Year field based on the Table Name field, and creating calculated fields to have versions of Calls and Revenue that only include the values for that one.

Elevate your data visualization skills with our Tableau Course and unleash the power of insightful analytics.

answered Apr 5, 2022 by Neha
• 9,060 points

Related Questions In Tableau

0 votes
1 answer

How to get multiple Sets of Measure Names with different Filters on a single sheet in Tableau?

The easiest solution to your query is: 1) ...READ MORE

answered Aug 23, 2018 in Tableau by Naruto
• 710 points
14,774 views
0 votes
1 answer

How to color code cells of a column based on the text value in Tableau

You can use the following steps to ...READ MORE

answered Mar 27, 2018 in Tableau by Atul
• 10,240 points
9,428 views
0 votes
0 answers

How to merge two data sets in Tableau via relationship?

I'd want to integrate two data sets ...READ MORE

Apr 14, 2022 in Tableau by Neha
• 9,060 points
929 views
0 votes
1 answer

How to calculate the percent of records within a group in tableau?

 You can click the measure SUM(Number of Records) and ...READ MORE

answered May 9, 2018 in Tableau by ffdfd
• 5,550 points
4,442 views
0 votes
1 answer

I can't get a graph out of my information

Hi@lzzy, According to your error, there is a ...READ MORE

answered Jun 11, 2020 in Python by MD
• 95,440 points
613 views
0 votes
0 answers

Using Python and Tableau in conjunction with one another

Is it possible to mix Python visualisations ...READ MORE

Feb 28, 2022 in Tableau by Vaani
• 7,020 points
332 views
0 votes
0 answers

Tableau Desktop Inside Tableau Server

Is there an executable for Tableau Desktop ...READ MORE

Feb 28, 2022 in Tableau by Vaani
• 7,020 points
347 views
0 votes
0 answers

Tableau Map view Continent List

I've been attempting to tidy up my ...READ MORE

Feb 28, 2022 in Tableau by Vaani
• 7,020 points
423 views
0 votes
1 answer

How to print projects and workbook names based on site id in tableau server client?

Here's how I do it once I've ...READ MORE

answered Mar 9, 2022 in Tableau by Neha
• 9,060 points
1,454 views
0 votes
1 answer

How to upload data to Tableau Server in Python

Then install the tableau-api-lib utility for Python ...READ MORE

answered Mar 4, 2022 in Tableau by Neha
• 9,060 points
1,829 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP