Tableau Sales Dashboard Tutorial using Table Calculations

In this Tableau data visualization tutorial, we’ll learn to use the LOOKUP table calculation function to return sales revenue for the same day last year. A number of different techniques are used in the creation of this dashboard.

I designed this dashboard solely as a teaching exercise to help you understand the LOOKUP function and how to show the same date last year in a separate column.

  • As we learned in a previous video Tableau Table Calculations Simplified, (make sure to watch this video afterwards for more clarity), we’ll compute using specific dimensions and then use “At the level” to make sure our LOOKUP table calculation is performing correctly.
  • The “Show Missing Values” option is selected to fill in date gaps in the data set that do not exist. Ensuring 365 dates per year are present in the visualization enables the offset (i.e., -1) in the LOOKUP calculation to arrive at correct sales revenue from the same day in the previous year.
  • You’ll learn that we can filter on a table calculation by using another table calculation. Filters based on table calculations do not filter out underlying data. Instead, the data is hidden from the view, allowing dimension members to be hidden from the view without impacting the data in the view.

Tableau Order of Operations

Observe the Tableau filter order of operations above. Applying a dimension filter before the Table Calculation filter removes underlying data which affects the proper functioning of Table calculations. Typically, Table Calculations only work on values that are visible in the view. By applying a table calculation (which is last in the order of operations) you preserve underlying data but filter out data from the view.

Interact with this dashboard via the picture link:

You need to read these posts and watch these videos for additional information:

As always, If you find this type of instruction valuable make sure to subscribe to my Youtube channel.

All views and opinions are solely my own and do NOT necessarily reflect those my employer.

Advertisements

Tableau Sales Dashboard Tutorial: Year Over Year Comparison

In this Tableau data visualization tutorial I used a technique shared by Tableau Zen Master Ryan Sleeper to “equalize” dates across the same axis. This date equalization calculated field enables year over year, quarter over quarter, month over month, week over week and same day last year comparisons.

MAKEDATE(2018,MONTH([Your Date]), DAY([Your Date]))

Equalizer 2

Call in The Equalizer for this Analysis

It’s a pretty clever way of preserving the same month and day of date values across many years and updating their respective years to one common year.

For example, all dates would retain their current month and day but would share the year value of ‘2018’. In this manner, data points from various years can be stacked on top of each other for comparison purposes.


Additionally, by creating a parameter value for a specific date part (i.e., year, month, week, etc.,) the user has control over the level of comparisons in the visualization.

You’ll have to watch the video to see the details. Again, thanks to Ryan Sleeper for sharing this tip with the Tableau community which enabled me to apply it to my dataset and share it with you in video form.

As always, If you find this type of instruction valuable make sure to subscribe to my Youtube channel.

All views and opinions are solely my own and do NOT necessarily reflect those my employer.

Tableau Table Calculations Made Simple

In this Tableau tutorial I will discuss a basic quick table calculation and try to demystify what is happening behind the scenes. All of the following will hopefully be made more clear in the video but I’m sharing the text below for reference after you watch the video.

I can’t take credit for the content in this post as the Tableau online help site has some quality information on table calculations which I will reference below. There are two important concepts in understanding table calculations: partitioning and addressing.

Key Concepts with Table Calculations: Addressing vs. Partitioning

The dimensions that define how to group the calculation (the scope of data it is performed on) are called partitioning fields. The table calculation is performed separately within each partition.

Partitioning fields break the view up into multiple sub-views (or sub-tables), and then the table calculation is applied to the marks within each such partition.

The remaining dimensions, upon which the table calculation is performed, are called addressing fields, and determine the direction of the calculation.

The direction in which the calculation moves (for example, in calculating a running sum, or computing the difference between values) is determined by the addressing fields.

So when you order the fields in the Specific Dimensions section of the Table Calculation dialog box from top to bottom, you are specifying the direction in which the calculation moves through the various marks in the partition.

When you add a table calculation using the Compute Using options, Tableau identifies some dimensions as addressing and others as partitioning automatically, as a result of your selections.

But when you use Specific Dimensions, then it’s up to you to determine which dimensions are for addressing and which for partitioning.

At the level (Partitioning)

The At the level option is only available when you select Specific Dimensions in the Table Calculations dialog box, and when more than one dimension is selected in the field immediately below the Compute Using options —that is, when more than one dimension is defined as an addressing field.

This option is not available when you’re defining a table calculation with Compute Using, because those values establish partitions by position. But with Specific Dimensions, because the visual structure and the table calculation are not necessarily aligned, the At the level option is available to let you fine-tune your calculation.

Use this setting to set a break (that is, restart of the calculation) in the view, based on a particular dimension. How is this different from just using that dimension for partitioning? In fact, it is partitioning, but it’s partitioning by position rather than by value, which is how partitioning is defined with the Compute Using options.

Filtering on Table Calculations in Tableau

Filtering on Table Calculations in Tableau can be a bit hacky. More often than not, table calculations are dependent upon the data in the view. That means in order to filter on a table calculation, we need a way to preserve underlying data and only hide data from the view.

Filters based on table calculations do not filter out underlying data in the data set, because table calculation filters are applied last in the order of operations. Instead, the data is hidden from the view, allowing dimension members to be hidden from the view without impacting the data in the view.

Notice in the order of operations diagram below how Dimension and Measure filters are applied before Table calculation filters. When trying to filter on a table calculation (which is dependent upon the data in the view) the results may be unexpected. If we turn our dimension or measure into a table calculation, we can then filter the Table calculation at the appropriate level, which preserves underlying data and only hides the table calculation values we wish to filter from the view.

Tableau Order of Operations

The content in this post was quoted from the sources below.

As always, If you find this type of instruction valuable make sure to subscribe to my Youtube channel.

References:

All views and opinions are solely my own and do NOT necessarily reflect those my employer.

Power BI Dashboard Tutorial: Year over Year Difference Analysis

I want you to increase your efficiency and to stop using spreadsheets for every single analysis.

Everybody works with time series data at some point in time. Year over year (also known as YoY) analysis is one of the most useful analyses you can perform to determine changes, analyze growth and recognize trends in quantity on an annual basis.

Unfortunately, most data preparers are used to performing some unaesthetic flavor of this analysis using only Excel (looking at you FP&A). Without the benefit of using visualization to easily recognize trends, data consumers are forced to work harder to tease out the most salient information.

If you have access to Power BI Desktop (available for free), then you can perform a tabular year over year difference calculation and then tie that information to a bar chart that will help you visualize the variances.

In this video I will show you how to create a calendar table in DAX (Microsoft’s formula expression language) and use that table to enable a year over year analysis of customer orders at fictional Stark Industries. You don’t need to be an expert in DAX to take advantage, just type in the date calendar formula you see in the video and tweak the simple calculations to fit your data.

You could obviously perform a simple YoY analysis in Excel, but I want you to stay relevant and learn something new!

If you find this type of instruction valuable make sure to subscribe to my Youtube channel.

 

Tableau Dashboard Tutorial: Dot Strip Plot

In this video tutorial I describe a dashboard that I put together that displays the distribution of various NBA player statistics. I use the always handy parameter to enable the user to choose which statistics are displayed on the dashboard. Although I’m showing sports statistics measures in this dashboard, it could easily be repurposed to show the distribution of a variety of business related metrics.

I break the dashboard up into three areas: histogram, dot strip plot, and heat map. In the second part of the video, I describe in detail how to build out a jittered dot strip plot. The benefit of the jittered dot strip plot is that the marks representing NBA players obstruct each other much less as compared to the linear dot strip plot.

Techniques used in the dashboard were previous outlined in my Ultimate Slope Graph and How to Use Jittering in Tableau (Scattered Data Points) posts.

Feel free to head to my Tableau Public page and download the workbook for yourself. Drop me a line in the comments or on YouTube if you learned something.

As always, do great things with your data!

If you find this type of instruction valuable make sure to subscribe to my Youtube channel.

Walmart Technology Brief: April 2019

March 30th, 2019
photo courtesy of technologyreview.com

The King has Left the Building

Jeremy King, Walmart’s Chief Technology Officer for the past 8 years is leaving the company. Mr. King is taking his talents from Bentonville, Arkansas to Silicon Valley. Specifically, to pre-IPO unicorn Pinterest, where he will serve as the company’s Chief Engineering Officer reporting directly to the CEO. CNBC reports that he will be accountable for Pinterest’s “visual discovery engine” that recommends posts and images to Pinterest users. Pinterest had Mr. King pinned on their board as he represents a splashy technical hire that is strategically happening before the company files for an IPO.

King will be replacing Pinterest’s outgoing head of engineering Li Fan who is scooting to become the head of engineering for Lime.

As the head of Walmart Labs, King was instrumental in revamping the company’s e-commerce technology and bringing cutting edge innovations to stores such as automated shelf scanning robots, in-store pickup and grocery delivery. He led the company through more than 10 acquisitions and spearheaded the organization’s transition to the cloud (although not the Amazon Cloud for obvious competitive reasons).

He also championed open source development at Walmart due to the company’s “build rather than buy” philosophy. The organization has historically held the belief that their information systems provide a competitive advantage over other industry players. Additionally, a third party developing custom systems for an organization the size of Walmart would encounter a Herculean task. The Wall Street Journal quoted King as stating, “You would be surprised at the list of companies that have completely choked on Walmart’s scale, because no one really builds products for Fortune One,”.

King’s last day with Walmart is March 29th 2019.

JetBlack

The Wall Street Journal reported on Walmart’s upscale, member’s only, text to order service that is targeted to wealthy NYC moms. For $50 a month, a small beta group in Manhattan will have access to personal shoppers/couriers that will white-glove deliver any non-food item on the same day as the order. The service, named “JetBlack”, is being helmed by Jenny Fleiss of Rent the Runway fame.

The items are wrapped in black (the “Black” in JetBlack) and the idea is a pet project of Jet.com co-founder Marc Lore (the “Jet” in JetBlack). Currently, the initiative is not profitable but its larger aim is to train AI powered systems that could one day “..power an automated personal-shopping service, preparing Walmart for a time when the search bar disappears and more shopping is done through voice-activated devices,” per Jenny Fleiss. JetBlack is essentially a research initiative on AI.

Surprisingly, the service does not restrict users to items only available through Walmart properties and subsidiaries. If a customer wants an Amazon product, then JetBlack will complete the request. Why the customer wouldn’t just order off Amazon themselves is anyone’s guess.

Walmart will be able to inventory the products that their members use after an initial in home visit and the company is building up a trove of data on the products that their wealthy clients order. In this age of data as power, Walmart is taking steps to gather valuable data on upscale clientele which could prove useful in its ongoing battle with Amazon.

Walmart Games?

A number of established tech players have announced or not officially announced their intentions to bring video game streaming to the masses; “Netflix for gaming” is the metaphor. Removing expensive hardware from the gamer equation and running games from giant data centers enables gamers to game with nothing more than a browser, tablet or smart phone.

Google made a big splash recently when it unveiled its cloud based gaming platform named Stadia at the 2019 Game Developers Conference. Microsoft has xCLoud, Amazon has a yet unnamed gaming platform and even Verizon is testing a gaming app on Nvidia Shield.

Walmart, yes Walmart is also rumored to be in on the action with the development of their own streaming game platform. Before we dismiss this as a flight of fancy, consider that Walmart already owns streaming video platform Vudu, where it can leverage existing technology and resources.

It is not known how far along Walmart is in the development process but I would suspect that this initiative is once again driven by the need to keep pace with Amazon.

For more Walmart technology coverage please check out Part 1Part 2 and Part 3 of my series on Walmart’s overall technology strategy.

Additional Walmart technology coverage can be found here

If you’re interested in Business Intelligence & Tableau check out my videos here: Anthony B. Smoak

References:

  1. Pinterest hires Walmart CTO ahead of IPO. CNBC. (March 21, 2019). https://www.cnbc.com/2019/03/21/pinterest-hires-walmart-cto-jeremy-king-ahead-of-ipo.html
  2. Pinterest Pins Tech Hopes on Walmart Technology Chief. Wall Street Journal. (March, 21, 2019). https://www.wsj.com/articles/pinterest-pins-tech-hopes-on-walmart-technology-chief-11553209071
  3. Walmart Builds a Secret Weapon to Battle Amazon for Retail’s Future. (March, 21, 2019). https://www.wsj.com/articles/walmart-builds-a-secret-weapon-to-battle-amazon-for-retails-future-11553181810
  4. Walmart May Follow Google’s Cue On Game Streaming. Android Headlines. Report (March 22, 2019).https://www.androidheadlines.com/2019/03/walmart-google-game-streaming-service.html
  5. Walmart is reportedly considering taking on Google and Microsoft with a video game streaming service. Business Insider. (March 21, 2019). https://www.businessinsider.com/walmart-video-game-streaming-google-stadia-2019-3

Create Rounded Bar Charts in Tableau

Part 1: How to Make Rounded Bar Charts in Tableau

In this post you’re getting two videos for the price of one (considering they’re all free for now, that’s a good thing). I put together a relatively simple dashboard to help illustrate a few intermediate level concepts. In this first video I take a look at the number of total assists by NBA players during the 2017-2018 season. In case you were wondering, Russell Westbrook led the league in assists during that season. If you don’t know who Russell Westbrook is, then skip this Tableau stuff and watch the last video immediately (and then come back to the Tableau stuff).

In the first Tableau dashboard video, you’ll learn two concepts:

  • How to make rounded bar charts;
  • How to filter the number of bar chart marks via use of a parameter;

Part 2: Apply Custom Sorting in Tableau

In the second video I build upon the dashboard built in the first video by showing you how to add a custom sort. The custom sort relies upon the creation of a parameter and a calculated field. The parameter and calculated field enable the user to select either a dimension (e.g., Player Name) or a measure (e.g., sum of assists) from a drop down box and the visualization will sort ascending or descending as requested.

The calculated field relies upon the RANK_UNIQUE function.

In this context, RANK_UNIQUE returns the unique rank of each player’s assist total. The key with RANK_UNIQUE is that identical values are assigned different ranks. As an example, the set of values (6, 9, 9, 14) would be ranked (4, 2, 3, 1), as no tied rankings are allowed.

Part 3: Interact with the Dashboard

Bonus: Russell Westbrook on the Attack

For those of you who do not know who Russell Westbrook is, I’ve got you covered. These aren’t assists but in these situations, he didn’t need to pass!

References:

Thanks to both the Tableau Magic blog for outlining the concept of rounded bar charts and the VizJockey blog for the custom sort methodology. Check out and support these  blogs!

As always, do great things with your data!

If you find this type of instruction valuable make sure to subscribe to my Youtube channel.