4 Replies Latest reply on Jul 5, 2018 11:22 PM by Ahamed Basha

# Team, I have to total difference of Employee count in a bar chart

Team,

I have to calculate the Head count difference at the end of the bar chart like this.

I have to show total count in the end of the bar chart respectively for each location and with the corresponding month.

Data:

 Current  Year Report Month Location Metrics Employee count Total Hc 2018 May EGS India Total HC 14664 2018 May EGS India CTR Count 1695 2018 May EGS India Night Shift Count 1567 2018 May EGS India Misc 301 2018 May EGS India Interns 0 11101 14664 - 1695 - 1567 -301 = 11101 2018 May WFC-Bangalore Total HC 6784 2018 May WFC-Bangalore CTR Count 953 2018 May WFC-Bangalore Night Shift Count 518 2018 May WFC-Bangalore Misc 136 2018 May WFC-Bangalore Interns 0 5177 6784 - 953 - 518 - 136 = 5177 2018 May WFC-Hyderabad Total HC 7335 2018 May WFC-Hyderabad CTR Count 706 2018 May WFC-Hyderabad Night Shift Count 788 2018 May WFC-Hyderabad Misc 162 2018 May WFC-Hyderabad Interns 0 5679 7335-706-788-162 = 5679 2018 May WFC-Chennai Total HC 545 2018 May WFC-Chennai CTR Count 36 2018 May WFC-Chennai Night Shift Count 261 2018 May WFC-Chennai Misc 3 2018 May WFC-Chennai Interns 0 245 545-36-261-3 = 245

Message was edited by: Ahamed Basha

• ###### 1. Re: Team, I have to calculate sum of total sales from Jan to Dec months and difference of particular month

I don't understand the last part, but you can do the first part with a running total

Once the measure is on the sheet, right-click on the field and choose Quick Table Calculation, and then Running Total

• ###### 2. Re: Team, I have to calculate sum of total sales from Jan to Dec months and difference of particular month

HI Chris,

I am getting the first part easily with running total calculation or running sum by writing a calculation.

For example

For March month report:

IF I select Jan(-483907 + 122842) = (-361064)(India & Philippines)

IF I select Feb ( (-483907-201498) -  (122842 + 304467.2) = -258905 (India & Philippines)

PFB the screenshot:

Hope this understand!

• ###### 3. Re: Team, I have to calculate sum of total sales from Jan to Dec months and difference of particular month

FYI.

Please find the tableau workbook and excel sheet.

• ###### 4. Re: Team, I have to total difference of Employee count in a bar chart

Tableau screenshot