Posts tagged reference line

Week 46: America’s Aging Population

It’s been way too long since I’ve given you all a challenge. I’ve really enjoyed learning set actions the past two weeks, but if you know anything about me, you know I love table calcs. So guess what? I’m back with a table calcs challenge for you; I know deep down you’ve missed them.

In this week’s Workout Wednesday, you have to rebuild this chart I made for Makeover Monday week 45.

click to view on Tableau Public

Click here to see the original on my blog. NOTE: I disabled download on the workbook on Tableau Public to force you to think through the solution. Yes, I know it’s mean, but you’ll learn more this way.


  • You may ONLY use table calcs. NO LODs.
  • Dashboard size: 800 x 700
  • You may only use one sheet.
  • Match the title, column headers and row headers.
  • You need to show the sex across the view and origin down the view. Make sure your sort order matches.
  • Each line represents the percentage of the total population for that age group for that year.
  • Each line must have a dot on the end.
  • The labels must be on the outside ends of the lines. The labels should be displayed as percentages to one decimal place. These are Tableau Medium 8pt. They must match the color of their respective lines.
  • Make sure the labels have enough space to display. You MAY NOT manually fix the axis.
  • I should only see 2016 and 2060 on the axis. There needs to be light grey gridlines for each of those two years.
  • For each section where the older generation (65+) crosses the younger generation (Under 18), you need display a black dot on the year that 65+ overtook Under 18.
  • You must display a dashed line with the year on the bottom right of the line for those lines that cross. The line needs to be at the same year as the black dot.
  • Match the tooltips (they show the year, the total population for each gender, and the percentage of the population for each gender.
  • The orange color is #E85839 (for 65+). The blue color is #3B6A9C (for Under 18).
  • Only show horizontal divider lines; no vertical divider lines.


Data from this week comes from Makeover Monday week 45 on Download here if needed.


After you finish your workout, share on Twitter using the hashtag #WorkoutWednesday2018 and tag @VizWizBI, @AnnUJackson, @LukeStanke, @RodyZakovich, @lorna_eden, and @curtisharris_.


Also, don’t forget to track your progress using this Workout Wednesday form.


  • You will need a dual-axis chart, both of which are table calcs.
  • All four data points in the tooltip require table calcs.
  • The dashed vertical line requires a table calcs.
  • Create calculations to offset the years to give the ends of the lines enough space to display the labels properly.

Week 25: Segmentation Drift

This week we start using the analytical tools — specifically clustering. Tableau’s built in cluster algorithm can be used to do customer segmentation. But instead of doing this by customer we are going to keep it simple by using sub-category and region.


click to view on Tableau Public



click to view on Tableau Public


  • Dashboard size is 700 x 800; tiled; 2 sheets
  • Create clusters using Profit Ratio (Total Profit/Total Sales) and average discount from only 2015 for sub-category and region. This is the basics of segmentation
  • Show the consistency of each cluster by plotting this over year, as well.
  • Match tooltips.
  • Label the clusters in 2015. Only show the label once. Don’t place many marks of text on top of each other.
  • Match color and formatting. I’ll be paying attention to all parts.
  • JEDI ONLY: Create hub-and-spoke plots that connect the center of each cluster to the value sub-category/region combinations that are part of the 2015 cluster.



This week uses the superstore dataset for Tableau 2018.1.  You can get it here at



After you finish your workout, share on Twitter using the hashtag #WorkoutWednesday and tag @AnnUJackson, @LukeStanke, and @RodyZakovich.  (Tag @VizWizBI too – he would REALLY love to see your work!)


Track your progress

Also, don’t forget to track your progress using this Workout Wednesday form.



  • Download the data from It’ll be easier with a .csv or .xlsx
  • You’ll need to union the data to itself.
  • Create some of the calculations to run when the [Table Name] = “Orders$”
  • For the clusters: filter the data to 2015. Build the chart with the measures of average discount and profit ratio and the dimensions of sub-category and region. Save the cluster as a dimension/group.
  • Size of the hub circle is 20x the other values.
  • You can always download the workbook for more help.