3 Replies Latest reply on Aug 26, 2015 10:13 PM by John Weisenfeld

    How Do I Create a Measure that Is a Difference Between Two Aggregates?

    John Weisenfeld

      I'm having fun dissecting State of WA Education salary data.  (Check out my vizzes at: | Tableau Public)


      But, school starts soon, and for some reason I can't show:  difference between average salary for Male and Female teachers.

      My database is broken down in a usual way, I want to calculate Avg(Male Teacher Salary) and subtract avg(Female Teacher Salary).  I have some complicated filters to verify integrity of the data (e.g. no duplicates) and it seems like I want to change one part of filter i.e. ***=M, get a number and then change filter ***=F, get a number, and then difference of those two numbers.


      Am I making this harder than it has to be?  Or is there some secret sauce in Tableau that I don't know yet...