
1. Re: Yearoveryear with a % change
Matt Lutton Sep 5, 2017 8:52 AM (in response to Tim Cady)Post a sample TWBX with what you currently have, and we can easily show you how to apply a YoY change Table Calculation to the view. Its difficult to provide help without seeing any data/workbook, but you can use the Sample Superstore datasets that ship with Tableau, or your own randomized subset of data to ask your question here on the Community Forums  but a workbook will allow volunteers to see/understand your data, and apply the help you need. At first glance, it seems like a simple Percent Difference table calculation, but its hard to know for sure without seeing a .TWBX file.

2. Re: Yearoveryear with a % change
MarcAnthony Di Biase Sep 5, 2017 8:53 AM (in response to Tim Cady)You can use an LOD calculation to calculate the columns by year, however I believe the level of detail you are after aggregates the KPI number and the Year together. In this case, your data is not structured optimally, and I would recommend pivoting your data such that you have a field called 'KPI' which would hold the values '1', '2' and '3'. This should also be applied to the date fields (if they are not already pivoted) such that you have a field for 'Date' or 'Year' that holds the values '2016' and '2017' (and all values moving forwards)
Here is a guide to help you with pivoting: Pivot Data from Columns to Rows
Once this is accomplished you can use the following formula:
{FIXED [Year],[KPI] : sum([Sales])}
Which will give you the sales (assumption that these are sales figure) value for each KPI for a given year.
Let me know if this is what you were after or if I've missed the mark!

3. Re: Yearoveryear with a % change
Jim Dehner Sep 5, 2017 9:00 AM (in response to Tim Cady)Hi Tim yes you can do it with a table calculation or your can write your own
The formula is
(LOOKUP(sum([Sales]),0)  LOOKUP(sum([Sales]),1) )/LOOKUP(sum([Sales]),1)
or you will get the same if you use the table calc
Either way the results are the same
The Grand Total option will take the formula and apply it to the totals row
Jim
If this posts assists in resolving the question, please mark it helpful or as the 'correct answer' if it resolves the question. This will help other users find the same answer/resolution. Thank you.

diff %.twbx 1.2 MB


4. Re: Yearoveryear with a % change
Jim Dehner Sep 5, 2017 9:19 AM (in response to Tim Cady)Thanks Ti,
Glad to help out
Jim