2 Replies Latest reply on Jan 18, 2012 5:37 AM by Jonathan Drummey

# Dual axis formatting - hiding first year for one but not for the other

Hi all, I just really started working with Tableau so apologies if this question is too basic.

Trying to keep it short, I have managed to plot a measure (i.e. Value(\$) (bar)) and its calculated year-on-year growth rate (grey line).

I need to NOT to show the growth rate for 2006 whilst still showing the other measure. I tried everything I could think of but I just can’t manage to get rid of the 2006 year-on-year growth rate value without also eliminating the “Value(\$)” bars.

Has anyone ever come across anything similar?

P.s. I am using this formula to calculate the y-o-y growth rate so that it returns 0 for the 2006 year in each region

if attr([year])> 2006 THEN (ZN(SUM([Value(\$)])) - LOOKUP(ZN(SUM([Value(\$)])), -1)) / ABS(LOOKUP(ZN(SUM([Value(\$)])), -1)) ELSE 0 END

• ###### 1. Re: Dual axis formatting - hiding first year for one but not for the other

It sounds like you need to alter your formula to return a null for the 2006 YoY calculation (assuming that's what would be returned without forcing it to 0) then you can hide this using the Format - Special Values section. If that doesn't work you can try filtering out the NULL value.

This post on hiding null values in Tableau might be useful to you

If you alter the YoY formula so it returns the 2006 value to NULL then you need to be careful about filtering out the 0 values in case there's a genuine 0 appearing in your results.

• ###### 2. Re: Dual axis formatting - hiding first year for one but not for the other

You'll need to change the ELSE 0 in your calculation to ELSE Null, and then set up the measure to hide Null values, using the instructions here:

http://onlinehelp.tableausoftware.com/v6.1/pro/online/en-us/i1139656.html