
1. Re: Dual axes using quick table calculation and measure
Tom W Dec 13, 2016 3:29 PM (in response to Tony Alderton)Yes, this works. Synchronize axis will also work.
Please attach a Tableau Packaged Workbook so we can replicate your issue with your data.

2. Re: Dual axes using quick table calculation and measure
Tony Alderton Dec 13, 2016 4:09 PM (in response to Tom W)Tony Alderton
Senior Strategy Analyst
Analysis, Policy and Research
Catholic Education Melbourne
Ph: +61 3 9267 0260 Fax: +61 3 9415 9325
228 Victoria Parade, East Melbourne
(PO Box 3, East Melbourne Vic 8002)
talderton@ceomelb.catholic.edu.au<mailto:talderton@ceomelb.catholic.edu.au>
www.ceomelb.catholic.edu.au<applewebdata://C5C7BBA38E3A42DDAB74185B0BB75E2A/www.ceomelb.catholic.edu.au>

Sample.twbx 28.6 KB


3. Re: Dual axes using quick table calculation and measure
Tom W Dec 13, 2016 4:31 PM (in response to Tony Alderton)Right click your axis on the left, select format. Click the 'axis' tab in the format pane on the left and change the number format to Number (Custom) and set it to 4 decimal places. Tell me what you see for the left axis versus the right?

4. Re: Dual axes using quick table calculation and measure
Tony Alderton Dec 13, 2016 4:37 PM (in response to Tom W)Hi,
I have done that and see this:
Thanks
Tony Alderton
Senior Strategy Analyst
Analysis, Policy and Research
Catholic Education Melbourne
Ph: +61 3 9267 0260 Fax: +61 3 9415 9325
228 Victoria Parade, East Melbourne
(PO Box 3, East Melbourne Vic 8002)
talderton@ceomelb.catholic.edu.au<mailto:talderton@ceomelb.catholic.edu.au>
www.ceomelb.catholic.edu.au<applewebdata://C5C7BBA38E3A42DDAB74185B0BB75E2A/www.ceomelb.catholic.edu.au>

image001.png 255.3 KB


5. Re: Dual axes using quick table calculation and measure
Tom W Dec 13, 2016 7:06 PM (in response to Tony Alderton)Take a closer look at your data; your left axis has a maximum value of 1, your right has a maximum value of 100.

6. Re: Dual axes using quick table calculation and measure
Tony Alderton Dec 13, 2016 11:09 PM (in response to Tom W)Hi,
The left axis is based on a percentage of ‘num’ which is simply ‘1’ for each case (I could have used distinct count of ‘student ID’ based on the categories of ‘correct’ which is either ‘0’ for ‘not correct’ or ‘1’ for correct. So yes, it would have a maximum value of 1. My question is whether a quick table calculation like this can be used in a dual axis with a ‘normal’ scale level measure. I think probably not. I suppose another way might be to create a calculated field that shows the total of ‘num’ if ‘correct’ = ‘correct’ divided by the total of ‘correct’ (both ‘correct’ and ‘incorrect’) multiplied by 100. But, unfortunately my SQL skills are not up to that.
Thanks
Tony Alderton
Senior Strategy Analyst
Analysis, Policy and Research
Catholic Education Melbourne
Ph: +61 3 9267 0260 Fax: +61 3 9415 9325
228 Victoria Parade, East Melbourne
(PO Box 3, East Melbourne Vic 8002)
talderton@ceomelb.catholic.edu.au<mailto:talderton@ceomelb.catholic.edu.au>
www.ceomelb.catholic.edu.au<applewebdata://C5C7BBA38E3A42DDAB74185B0BB75E2A/www.ceomelb.catholic.edu.au>

7. Re: Dual axes using quick table calculation and measure
Tom W Dec 14, 2016 6:32 AM (in response to Tony Alderton)Like I said, yes you can use a dual axis when one of the measures is a table calculation. You need to either divide the 0 to 100 measure by 100 or multiply the 01 measure by 100.
I.e. create a calculated field AVG([State Percentage])/100 and use that instead.

8. Re: Dual axes using quick table calculation and measure
Jonathan Drummey Dec 14, 2016 9:42 AM (in response to Tony Alderton)Here’s an updated view:
What I did was drag the % of total quick table calculation over to the Measures window and created a %age calculation, and edited the formula to multiply it by 100. Then for both measures I cleared the custom formatting done on the pills and changed the default number format to 0.0\% for each. The \ is necessary to stop Tableau from treating it as % and adding decimal places. Then I could synchronize the axes.
I also turned back on Include 0 for the bar chart axis, the reason why is that using truncating axes on bars is incredibly misleading because we interpret bars by the length of the bar. Here’s the view with truncated axes:
It makes it look like change change from 2014 to 2015 was a decline of 75%, when in fact it was 2.6%. If you really want to truncate the axes while showing trends then you're better off with a line chart or something else, here's a line chart:
Workbook is attached, let me know if you have any questions!
Jonathan

Sample2 jtd.twbx 83.3 KB


9. Re: Dual axes using quick table calculation and measure
Tony Alderton Dec 14, 2016 2:17 PM (in response to Jonathan Drummey)Thanks very much indeed Jonathan. That’s fantastic.
Tony Alderton
Senior Strategy Analyst
Analysis, Policy and Research
Catholic Education Melbourne
Ph: +61 3 9267 0260 Fax: +61 3 9415 9325
228 Victoria Parade, East Melbourne
(PO Box 3, East Melbourne Vic 8002)
talderton@ceomelb.catholic.edu.au<mailto:talderton@ceomelb.catholic.edu.au>
www.ceomelb.catholic.edu.au<applewebdata://C5C7BBA38E3A42DDAB74185B0BB75E2A/www.ceomelb.catholic.edu.au>

10. Re: Dual axes using quick table calculation and measure
Tony Alderton Dec 14, 2016 8:53 PM (in response to Jonathan Drummey)Sorry Jonathan. I have another question.
For some years in my chart one measure is ‘zero %’. I can put these in (Analysis, table layout, show empty columns and then format, special values, text = 0, show at default value) but then the other measure does not show. Any idea how I can get the other measure to show. Please see attached capture.
Thanks
Tony Alderton
Senior Strategy Analyst
Analysis, Policy and Research
Catholic Education Melbourne
Ph: +61 3 9267 0260 Fax: +61 3 9415 9325
228 Victoria Parade, East Melbourne
(PO Box 3, East Melbourne Vic 8002)
talderton@ceomelb.catholic.edu.au<mailto:talderton@ceomelb.catholic.edu.au>
www.ceomelb.catholic.edu.au<applewebdata://C5C7BBA38E3A42DDAB74185B0BB75E2A/www.ceomelb.catholic.edu.au>

Capture.PNG 20.2 KB
