
1. Re: Distribution Calculation Based On Product Category/Year
Andrew Watson Sep 2, 2016 11:12 AM (in response to Mat Henning)1 of 1 people found this helpfulSounds like you should be looking at LOD calculations. Check this out, very useful: Top 15 LOD Expressions  Tableau Software
As an example you could have (based on your example): {FIXED [Product Category], YEAR([OrderDate]): COUNTD([CustomerId])}. That will give you a fixed number of the total customers for each product category for each year. Effectively the denominator for your example calculations.
You can also try {INCLUDE [Product Category], YEAR([OrderDate]): COUNTD([CustomerId])}, which operates slightly differently then FIXED, especially when it comes to filters.
Note I haven't checked the field names of Superstore so please alter as necessary. If using Tableau 9 you'll have to put the YEAR([OrderDate]) into a seperate calculated field and call that calculated field instead of referencing the YEAR function.

2. Re: Distribution Calculation Based On Product Category/Year
Mat Henning Sep 2, 2016 11:49 AM (in response to Andrew Watson)Andrew,
Thank you! I'm almost there, but after using your example I came across another obstacle. I need it to only count customers within a customer category  IE Offices/Warehouses/Homes/ETC. Even when I apply filters it is calculating *all* customers that purchased from that product category, not just the one that I have filtered down to.
Mat

3. Re: Distribution Calculation Based On Product Category/Year
Andrew Watson Sep 2, 2016 12:59 PM (in response to Mat Henning)1 of 1 people found this helpfulYou can put your filters into Context  that should solve it if you're using FIXED.
Alternatively see if the INCLUDE formula works and please post back which you ended up going with

4. Re: Distribution Calculation Based On Product Category/Year
Mat Henning Sep 2, 2016 1:14 PM (in response to Andrew Watson)Context is what needed to happen. Now everything is working properly. THANK YOU SO MUCH!!!

5. Re: Distribution Calculation Based On Product Category/Year
Andrew Watson Sep 2, 2016 1:21 PM (in response to Mat Henning)1 of 1 people found this helpfulGreat, glad it's working for you and thanks for feeding back. Can you please mark one of the answers as correct to close out the thread? Thanks