Sunday, August 11, 2013

Side Effects Considered Harmful or Hey!? What happened to my Axis?

Clarity and predictability are hallmarks of good design. An object that offers an affordance suggests that something can be done to it. Two objects that offer the same affordance suggest that each can be operated individually via its affordance.

For example, when you approach a pair of doors, each with a "pull open" handle it's normal to expect that pulling on the left door's handle will open the left door towards you, and that pulling on the right door's handle will open the right door towards you. It would be confusing if the right door handle operated both doors and the left door handle operated only the left door. It would be even worse if using the right door handle made the left door handle disappear. Imagine the confusion this would create in the mind of someone expecting normal behavior.

Could something this weird happen in Tableau land?
Yes. This post presents, for your consideration:

The Case of the Disappearing Axis.


This is a typical Dual Axis chart.

The Sale axis is on the left, the Profit axis is on the right.

Each axis' pill on the Rows shelf has a "Show Header" option in its pull-down menu. The "Show Header" option is a toggle, switching the axis between being shown and hidden.

A reasonable expectation is that when one selects the "Show Header" option for either Sales or Profit the corresonding axis will be shown or hidden, depending upon its current state.

This is not quite true in Tableau.

Here's an example of an unexpected outcome.

Starting with the Dual Axis Chart at left, follow these simple steps:

Step 1.
    - select "Show Option from the Sales menu
    - Tableau hides both axes

Step 2.
    - select "Show Option from the Sales menu
    - Tableau shows the Sales axis

What happened to the Profit axis?
It wasn't touched and yet it's disappeared. This is bad.

Step 1.

You select the Sales "Show Header" option
expectation: Tableau will hide (unshow) the Sales axis


Tableau hides both axes.


Step 2.

You select the Sales "Show Header" option
expectation: Tableau will reverse the previous action, i.e. will Show both axes since it previously hid both of them


Tableau shows the Sales axis.

What? Something's not right here, but what?


Not sure –what– went wrong, although it really feels like something did?

There are actually two problems occurring at the same time, each of which is a problem, but when encountered in combination they create a confusion, a sense of disorientation in the mind of the person encountering them.

First Problem: non-local action.

The Sales' "Show Header" option is presented in a context that strongly associates it with, and only with, the Sales field, and by extension to the Sale axis.

However, when Sales' "Show Header" is selected to hide the Sales axis, it also hides Profit's axis. This action violates the sphere of influence that is implicit in the direct connection between Sales and its "Show Header" option.

This isn't good, but isn't all that bad in this scenario. Since the user has just taken a single action, and that action appears to be a toggle that switches states, it's only reasonable to think that throwing the switch in the other direction will reverse the situation and restore the system to its original state. Just like flipping a light switch turns it on and off. So the user toggles Sales' "Show Header" option again expecting to see both axes restored to visibility.

But that's not what happens.

Instead of both axes being shown, only Sales' is.

Second Problem: Operational Asymmetry.

In the context of this scenario, the Sales "Show Header" action works differently depending upon whether it's being used to show or hide:

  • Hide
    – when used to switch from show to hide, both axes are hidden
  • Show
    – when used to switch from hide to show, only the Sales axs is shown

As bad as non-local action is, it wouldn't be so harmful if the functionality of Sales "Show Header" option was symmetrical. If it showed or hid both axes at the same time it would be less flexible but also much less confusing.

And as bad it this scenario is, it's only part of the whole story.
Stay tuned for the next chapter in the thrilling adventures of Dual Axis Chart Axis Visibility Management.

Try this at home.

No comments:

Post a Comment